'); jQuery('#huge_it_videogallery_popup_list_2').insertBefore('#huge-popup-overlay-video_2'); var height = jQuery(window).height(); var width=jQuery(window).width(); //console.log(height) //console.log(width) if(width */ jQuery("#huge_it_videogallery_popup_list_2 .heading-navigation .left-change").click(function(){ //var strid = jQuery(this).closest(".pupup-element").prev(".pupup-element").find('a').data('popupid').replace('#',''); var height = jQuery(window).height(); //jQuery('#huge_it_gallery_pupup_element_'+strid).css({height:height*0.7}); var num = jQuery(this).find("a").attr("href").replace('#', ''); if(num >= 1){ var strid = jQuery(this).closest(".pupup-element").prev(".pupup-element").find('a').data('popupid').replace('#',''); jQuery('#huge_it_videogallery_pupup_element_'+strid).css({height:height*0.7}); jQuery(this).closest(".pupup-element").removeClass("active"); jQuery(this).closest(".pupup-element").prev(".pupup-element").addClass("active"); }else{ var strid = jQuery("#huge_it_videogallery_popup_list_2").find(".pupup-element").last().find('a').data('popupid').replace('#',''); jQuery('#huge_it_videogallery_pupup_element_'+strid).css({height:height*0.7}); jQuery(this).closest(".pupup-element").removeClass("active"); jQuery("#huge_it_videogallery_popup_list_2").find(".pupup-element").last().addClass("active"); } }); /* */ jQuery("#huge_it_videogallery_popup_list_2 .heading-navigation .right-change").click(function(){ var height = jQuery(window).height(); var num = jQuery(this).find("a").attr("href").replace('#', ''); var cnt = 0; jQuery("#huge_it_videogallery_popup_list_2").find(".pupup-element").each(function(){ cnt++; }); // alert(num+" "+cnt); if(num =768){ jQuery('#huge_it_videogallery_popup_list_2 .popup-wrapper_2 .image-block_2 iframe').height(jQuery(window).width()*0.20); }else{ jQuery('#huge_it_videogallery_popup_list_2 .popup-wrapper_2 .image-block_2 iframe').height(jQuery(window).width()*0.5); } }); });