1$(function() { 2 $('.closeBtn').live('click',function(e){ 3 e.preventDefault(); 4 $('.overlayAddEvent').fadeOut(); 5 $('body').removeClass("overflow"); 6 }) 7 $('.addToCal').live('click',function(e){ 8 e.preventDefault(); 9 var id = $(this).attr('rel'); 10 if(id){ 11 $.get('/?load=Open::Services::Common', { 12 action: 'getCalendarData', 13 id: id 14 }, function(data){ 15 data = jQuery.parseJSON(data); 16 if(data){ 17 $('.overlayAddEvent').fadeIn(); 18 $('body').addClass("overflow"); 19 20 var title = data.title; 21 var location = data.location; 22 var day = data.day; 23 var month = data.month; 24 var category = data.category; 25 var url = data.url; 26 var desc = new String(data.description); 27 28 var startDate = new Date(data.start); 29 var endDate = new Date(data.end); 30 var start = startDate.getFullYear()+''+twoDigits((startDate.getMonth()+1))+''+twoDigits(startDate.getDate())+'T'+twoDigits(startDate.getHours())+'0000'; 31 var end = endDate.getFullYear()+''+twoDigits((endDate.getMonth()+1))+''+twoDigits(endDate.getDate())+'T'+twoDigits(endDate.getHours())+'0000'; 32 var date = start+'/'+end; 33 34 $('.overlayAddEvent').find('.date').find('.month').text(month); 35 $('.overlayAddEvent').find('.date').find('.day').text(day); 36 $('.overlayAddEvent').find('.eventTitle').find('.color1').text(category); 37 $('.overlayAddEvent').find('.eventTitle').find('.color6').text(location); 38 $('.overlayAddEvent').find('.eventTitle').find('.color0').html(title); 39 40 41 $('.overlayAddEvent').find('.calOutlook').attr('href', '/?load=Open::Services::iCalendar&id='+id+'&rel=outlook');//Outlook 42 43 var yahooUrl = new String('http://calendar.yahoo.com/?v=60&TITLE='+title+'&ST='+start+'&in_loc='+location+'&DESC='+escape(desc) + ' ' + url+'&URL='+encodeURI(url)+'&END='+end); 44 if(yahooUrl.length > 470){ 45 yahooUrl = new String('http://calendar.yahoo.com/?v=60&TITLE='+title+'&ST='+start+'&in_loc='+location+'&DESC='+desc.substr(0,(desc.length - (470 - yahooUrl.length))) + ' ' + url+'&URL='+encodeURI(url)+'&END='+end); 46 } 47 $('.overlayAddEvent').find('.calYahoo').attr('href',yahooUrl);//yahoo 48 49 var googleUrl = new String('http://www.google.com/calendar/event?action=TEMPLATE&text='+title+'&dates='+date+'&details='+desc + ' ' + url+'&location='+location+'&trp=false&sprop=http://www.peika.bg&sprop=name:peika.bg'); 50 if(googleUrl.length > 400){ 51 googleUrl = new String('http://www.google.com/calendar/event?action=TEMPLATE&text='+title+'&dates='+date+'&details='+desc.substr(0,(desc.length - (googleUrl.length - 400))) + ' ' + url+'&location='+location+'&trp=false&sprop=http://www.peika.bg&sprop=name:peika.bg'); 52 } 53 $('.overlayAddEvent').find('.calGoogle').attr('href', googleUrl);//Google 54 } 55 }) 56 } 57 }) 58}) 59function twoDigits(number){ 60 if(number > 9){ 61 return number; 62 }else if(number <= 9 && number > 0){ 63 return '0'+number; 64 }else{ 65 return '00'; 66 } 67}
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.