jQuery(window).load(function(){ // IMAGE SLIDER HEIGH jQuery('.entry-image-slide').each(function(){ jQuery(this).height(jQuery(this).find('.imgSmall').height()); }); // IMAGE SLIDER HEIGHT jQuery(window).resize(function() { jQuery('.entry-image-slide').each(function(){ jQuery(this).height(jQuery(this).find('.imgSmall').height()); }); }); }); jQuery(document).ready(function(){ // MOBILE MENU jQuery('#main-menu-mobile').change(function(){ if(jQuery(this).val() !== null){ document.location.href = jQuery(this).val() } }); resize_video(); jQuery(window).resize(function(){ resize_video(); }); }); // VIDEO RESIZER function resize_video(){ if(jQuery(window).width()>989){ jQuery('.jp-jplayer-video').jPlayer({ size: { width: "580px", height: "326px" } }); } if(jQuery(window).width()<=989&&jQuery(window).width()>=767){ jQuery('.jp-jplayer-video').jPlayer({ size: { width: "436px", height: "245px" } }); } if(jQuery(window).width()<768&&jQuery(window).width()>=480){ jQuery('.jp-jplayer-video').jPlayer({ size: { width: "400px", height: "226px" } }); } if(jQuery(window).width()<480){ jQuery('.jp-jplayer-video').jPlayer({ size: { width: "240px", height: "135px" } }); } }