1jQuery(document).ready(function(){ 2 jQuery("body a[href$='.jpg'], body a[href$='.png'], body a[href$='.gif']").addClass('group1'); 3 4 5 jQuery('a[href*="youtube"]').not('.huge_it_gallery_item').not('.huge_it_videogallery_item').each(function(){ 6 jQuery(this).addClass('youtube').addClass('group1'); 7 var url = jQuery(this).attr('href'); 8 var videoid = url.match(/(?:https?:\/{2})?(?:w{3}\.)?youtu(?:be)?\.(?:com|be)(?:\/watch\?v=|\/)([^\s&]+)/); 9 jQuery(this).attr('href','https://www.youtube.com/embed/'+videoid[1]); 10 }); 11 12 13 jQuery('a[href*="vimeo"]').not('.huge_it_gallery_item').not('.huge_it_videogallery_item').each(function(){ 14 jQuery(this).addClass('vimeo').addClass('group1'); 15 var vimeourl = jQuery(this).attr('href'); 16 var vimeoid = vimeourl.substring(vimeourl.lastIndexOf("/") + 1, vimeourl.length); 17 jQuery(this).attr('href','http://player.vimeo.com/video/'+vimeoid); 18 }); 19 20 jQuery(".group1").colorbox({rel:'group1'}); 21 jQuery(".group2").colorbox({rel:'group2', transition:"fade"}); 22 jQuery(".group3").colorbox({rel:'group3', transition:"none", width:"75%", height:"75%"}); 23 jQuery(".group4").colorbox({rel:'group4', slideshow:true}); 24 jQuery(".ajax").colorbox(); 25 jQuery(".youtube").colorbox({iframe:true, innerWidth:640, innerHeight:390}); 26 jQuery(".vimeo").colorbox({iframe:true, innerWidth:500, innerHeight:409}); 27 jQuery(".iframe").colorbox({iframe:true, width:"80%", height:"80%"}); 28 jQuery(".inline").colorbox({inline:true, width:"50%"}); 29 jQuery(".callbacks").colorbox({ 30 onOpen:function(){ alert('onOpen: colorbox is about to open'); }, 31 onLoad:function(){ alert('onLoad: colorbox has started to load the targeted content'); }, 32 onComplete:function(){ alert('onComplete: colorbox has displayed the loaded content'); }, 33 onCleanup:function(){ alert('onCleanup: colorbox has begun the close process'); }, 34 onClosed:function(){ alert('onClosed: colorbox has completely closed'); } 35 }); 36 37 jQuery('.non-retina').colorbox({rel:'group5', transition:'none'}) 38 jQuery('.retina').colorbox({rel:'group5', transition:'none', retinaImage:true, retinaUrl:true}); 39 40 41 jQuery("#click").click(function(){ 42 jQuery('#click').css({"background-color":"#f00", "color":"#fff", "cursor":"inherit"}).text("Open this window again and this message will still be here."); 43 return false; 44 }); 45 46 47 48});
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.