1// (c) Lynx Information Systems Ltd 2023 2// Version history - see version.txt 3$(document).ready(function() { 4 5 function addAdviserLinks() { 6 // add Advisers Quick Links into right sidebar 7 $.get('advisers.html',function(data, status) { 8 var $links = $('a.adviser',data); 9 10 // sort links into alphabetical order 11 $links.sort(function(a,b) { 12 var compA = $(a).text().toUpperCase(); 13 var compB = $(b).text().toUpperCase(); 14 return (compA < compB) ? -1 : (compA > compB) ? 1 : 0; 15 }); 16 17 // V5.00 using tiles instead of lists for links 18 var $tile = $('<div>').addClass('sidebarTile').appendTo($('#QuickAdviserLinks')); 19 $links.each(function() { 20 $('<span>').addClass('tileText').append($(this)).appendTo($tile); 21 }) 22 }); 23 } // addAdviserLinks 24 25 function addBlogFeed() { 26 // add a div container 27 var $blogfeed = $('#blogfeed'); 28 $blogfeed.show(); 29 30 var $rssItems = $('.rssItems',$blogfeed); 31 32 // get blog feed as JSONP, avoids need for CORS headers 33 var active = true; 34 var xhr = $.getJSON("https://blogs.lynxinfo.co.uk/?feed=json&date_format=j+F+Y&jsonp=?"); 35 36 xhr.done(function(feedItems) { 37 active = false; 38 $('.rssLoading',$blogfeed).hide(); 39 40 // sequential animated show 41 (function showItem(item) { 42 $('<div>') 43 .addClass('rssItem') 44 .appendTo($rssItems) 45 .append($('<p>').addClass('rssItemDate').html(item.date)) 46 .append($('<p>').addClass('rssItemTitle').html($('<a>').attr('href',item.permalink).html(item.title))) 47 .append($('<p>').addClass('rssItemDescription').html(item.excerpt)) 48 .fadeIn(function() { // callback to show next item 49 if (feedItems.length>0) 50 showItem(feedItems.shift()) 51 }); 52 })(feedItems.shift()); 53 }); 54 55 setTimeout(function() { 56 if (active) { 57 xhr.abort(); 58 $('.rssLoading',$blogfeed).hide(); 59 $blogfeed.append('<span>Connection to blogs.lynxinfo.co.uk timed out</span>'); 60 } 61 },10000); 62 } // addBlogFeed 63 64 function showScrollingBanner() { 65 $(".marquee").fadeIn(600); 66 } // showScrollingBanner 67 68 showScrollingBanner(); 69 addAdviserLinks(); 70 addBlogFeed(); 71 72});
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.