1function customInit() { 2 textChange(); 3 $("#section-2 .box4 .navigation ul.level1").tabs("#section-2 .box4 div.records"); 4 $("#new_comment_form").validate(); 5 $(".related").click(function () { 6 $(".related").toggleClass("related-active"); 7 $(".related-box").slideToggle(250); 8 }); 9 10 require(['bundle/fetch-ec.bundle'], function(FetchEC) { 11 if($('#metered-message-ec').length !== 0) { 12 fetchMeteredEC(FetchEC); 13 } else { 14 // When Metered Notice is rendered from Evercookie, 15 // wait for the JS to add it to the DOM 16 $(document).on('epub.meteredNoticeReady', function() { 17 fetchMeteredEC(FetchEC); 18 }); 19 } 20 }); 21} 22 23function fetchMeteredEC(FetchEC) { 24 var ecName = 'metered.paywall.registration.message', // default message is metered.paywall.registration.message 25 isFinalMsg = $('#metered-message-ec').data('final'); 26 27 if($('body').data('article-requires-registration')) { 28 ecName = isFinalMsg ? 'metered.paywall.final.registration.message' : 'metered.paywall.registration.message' 29 } 30 31 if($('body').data('article-requires-subscription')) { 32 ecName = isFinalMsg ? 'metered.paywall.final.subscription.message' : 'metered.paywall.subscription.message' 33 } 34 35 new FetchEC.default('#metered-message-ec', { 36 name: ecName 37 }); 38} 39 40function textChange() { 41 $("a.changer").click(function () { 42 //set the div with class content as a var called $content 43 var $content = $('div.content'); 44 // set the current font size of .content as a var called currentSize 45 var currentSize = $content.css('font-size'); 46 // parse the number value out of the font size value, set as a var called 'num' 47 var num = parseFloat(currentSize, 10); 48 // make sure current size is 2 digit number, save as var called 'unit' 49 var unit = currentSize.slice(-2); 50 // javascript lets us choose which link was clicked, by ID 51 if (this.id == 'linkLarge') { 52 num = num * 1.4; 53 } else if (this.id == 'linkSmall') { 54 num = num / 1.4; 55 } 56 // jQuery lets us set the font Size value of the content div 57 $content.css('font-size', num + unit); 58 return false; 59 }); 60 // hover for links - toggle css background colors 61 $("a.changer").hover(function () { 62 $(this).css('background-color', '#3d3d3d'); 63 }, function () { 64 $(this).css('background-color', '#fff'); 65 }); 66 // hide textSize-layer on page load 67 $('.textSize-layer').hide(); 68 // show the textSize-layer div if textSize is clicked 69 $('.textSize').click(function () { 70 //$(this).hide(); 71 $('.textSize-layer').show(); 72 return false; 73 }); 74 // hide textSize-layer if it is clicked 75 $('.textSize-layer').click(function () { 76 $(this).hide(); 77 $('.textSize').show(); 78 return false; 79 }); 80} 81 82function popVideo(url) { 83 newwindow=window.open(url,'video','height=540,width=670,scrollbars=0,resizeable=0,menubar=0,toolbar=0,titlebar=0'); 84 if (window.focus) newwindow.focus(); 85 return false; 86} 87 88function updateMovie(url) { 89 $('#video1').html("<"+"div id='media"+"space'>This text will be replaced<"+"/"+"div><"+"scr"+"ipt type='text/javascript'"+">insertMovie('"+url+"')<"+"/scr"+"ipt>"); 90 $('html, body').animate({ 91 scrollTop: $("#video").offset().top 92 }, 2000); 93} 94 function insertMovie(url) { 95 var so = new SWFObject('/player.swf','mpl','640','500','9'); 96 so.addParam('allowfullscreen','true'); 97 so.addParam('allowscriptaccess','always'); 98 so.addVariable('autostart','true'); 99 so.addParam('wmode','opaque'); 100 so.addVariable('file',url); 101 so.addVariable('bufferlength','5'); 102 so.write('mediaspace'); 103}
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.