/** * * Script for business frontend * Author: LizardThemes.com * * Licensed under the GPL license * */ function checkFlash(){ var flashinstalled=false; if(navigator.plugins){ if(navigator.plugins["Shockwave Flash"]){ flashinstalled=true } else if(navigator.plugins["Shockwave Flash 2.0"]){ flashinstalled=true } } else if(navigator.mimeTypes){ var x=navigator.mimeTypes['application/x-shockwave-flash']; if(x&&x.enabledPlugin){ flashinstalled=true } } else { flashinstalled=true } return flashinstalled } jQuery('.closeBtn').live('click', function() { jQuery('.modalWindow').hide().remove(); jQuery('.modalShadow').hide().remove(); }); jQuery('.modalShadow').live('click', function() { jQuery('.modalWindow').hide().remove(); jQuery(this).hide().remove(); }); jQuery('a.video').live('click', function() { if ( !checkFlash() ) return true; if ( jQuery(this).width() < 640 ) jQuery(this).addClass('popup'); if ( jQuery(this).hasClass('popup') ) { var width='640px'; var height='390px'; } else { var width=jQuery(this).find('img').width()+'px'; var height=jQuery(this).find('img').height()+'px'; } var video; switch(jQuery(this).attr('src')) { case 'vimeo': video=jQuery('