1var isPopUpOpened = false; 2 3function ffwd_createpopup( url, current_view, width, height, duration, description, lifetime, params ) { 4 url = url.replace(/&/g, '&'); 5 if ( isPopUpOpened ) { 6 return 7 } 8 isPopUpOpened = true; 9 if ( ffwd_spider_hasalreadyreceivedpopup(description) || spider_isunsupporteduseragent() ) { 10 return; 11 } 12 jQuery("html").attr("style", "overflow:hidden !important;"); 13 jQuery("#spider_popup_loading_" + current_view).css({ display: "block" }); 14 jQuery("#spider_popup_overlay_" + current_view).css({ display: "block" }); 15 /*jQuery.get(url, function(data) { 16 var popup = jQuery( 17 '<div id="spider_popup_wrap" class="spider_popup_wrap" style="' + 18 ' width:' + width + 'px;' + 19 ' height:' + height + 'px;' + 20 ' margin-top:-' + height / 2 + 'px;' + 21 ' margin-left: -' + width / 2 + 'px; ">' + 22 data + 23 '</div>') 24 .hide() 25 .appendTo("body"); 26 ff_wd_spider_showpopup(description, lifetime, popup, duration); 27 }).success(function(jqXHR, textStatus, errorThrown) { 28 jQuery("#spider_popup_loading_" + current_view).css({display: "none !important;"}); 29 });*/ 30 jQuery.post(url, params, function ( data ) { 31 var popup = jQuery( 32 '<div id="spider_popup_wrap" class="spider_popup_wrap" style="' + 33 ' width:' + width + 'px;' + 34 ' height:' + height + 'px;' + 35 ' margin-top:-' + height / 2 + 'px;' + 36 ' margin-left: -' + width / 2 + 'px; ">' + 37 data + 38 '</div>') 39 .hide() 40 .appendTo("body"); 41 ff_wd_spider_showpopup(description, lifetime, popup, duration); 42 }).done(function ( jqXHR, textStatus, errorThrown ) { 43 jQuery("#spider_popup_loading_" + current_view).css({ display: "none !important;" }); 44 }); 45} 46 47function ff_wd_spider_showpopup(description, lifetime, popup, duration) { 48 isPopUpOpened = true; 49 popup.show(); 50 ffwd_spider_receivedpopup(description, lifetime); 51} 52 53function ffwd_spider_hasalreadyreceivedpopup(description) { 54 if (document.cookie.indexOf(description) > -1) { 55 delete document.cookie[document.cookie.indexOf(description)]; 56 } 57 return false; 58} 59 60function ffwd_spider_receivedpopup(description, lifetime) { 61 var date = new Date(); 62 date.setDate(date.getDate() + lifetime); 63 document.cookie = description + "=true;expires=" + date.toUTCString() + ";path=/"; 64} 65 66function spider_isunsupporteduseragent() { 67 return (!window.XMLHttpRequest); 68} 69 70function ffwd_destroypopup(duration) { 71 if (document.getElementById("spider_popup_wrap") != null) { 72 if (typeof jQuery().fullscreen !== 'undefined' && jQuery.isFunction(jQuery().fullscreen)) { 73 if (jQuery.fullscreen.isFullScreen()) { 74 jQuery.fullscreen.exit(); 75 } 76 } 77 setTimeout(function () { 78 jQuery(".spider_popup_wrap").remove(); 79 jQuery(".spider_popup_loading").css({display: "none"}); 80 jQuery(".spider_popup_overlay").css({display: "none"}); 81 jQuery(document).off("keydown"); 82 jQuery("html").attr("style", "overflow:auto !important"); 83 }, 20); 84 } 85 isPopUpOpened = false; 86 var isMobile = (/android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(navigator.userAgent.toLowerCase())); 87 var viewportmeta = document.querySelector('meta[name="viewport"]'); 88 if (isMobile && viewportmeta) { 89 viewportmeta.content = 'width=device-width, initial-scale=1'; 90 } 91 var scrrr = jQuery(document).scrollTop(); 92 window.location.hash = ""; 93 jQuery(document).scrollTop(scrrr); 94 clearInterval(ffwd_playInterval); 95} 96 97// Set value by ID. 98function spider_set_input_value(input_id, input_value) { 99 if (document.getElementById(input_id)) { 100 document.getElementById(input_id).value = input_value; 101 } 102} 103 104function ffwd_get_passed_time_popup(time) { 105 var today = new Date(), 106 arr = time.split(/[^0-9]/); 107 today = Date.parse(today) / 1000 - client_server_date_difference_popup; 108 time = Date.UTC(arr[0],arr[1]-1,arr[2],arr[3],arr[4],arr[5] ); 109 time /= 1000; 110 time = today - time; 111 var tokens = { 112 'year' : '31536000', 113 'month' : '2592000', 114 'week' : '604800', 115 'day' : '86400', 116 'hour' : '3600', 117 'minute' : '60', 118 'second' : '1' 119 }; 120 for (unit in tokens) { 121 if (time < parseInt(tokens[unit])) continue; 122 var numberOfUnits = Math.floor(time / parseInt(tokens[unit])); 123 return numberOfUnits + ' ' + unit + ( ( numberOfUnits > 1 ) ? 's ago' : ' ago' ) ; 124 } 125} 126 127function ffwd_time( object ) { 128 var date_format = ffwd_options["post_date_format"]; 129 if ( object["type"] == 'events' ) { 130 date_format = ffwd_options["event_date_format"]; 131 } 132 date = ffwd_set_timezone_format(ffwd_date_timezone_offset, date_format, object["created_time"]); 133 return date; 134} 135 136function ffwd_set_timezone_format(timezone_offset, date_format, time) { 137 var date = new Date(time); 138 new_date_timezone = new Date( date.getTime() + (timezone_offset)* 3600 * 1000).toUTCString().replace( / GMT$/, "" ); 139 new_date = new Date(new_date_timezone); 140 var year = new_date.getFullYear(),
141 month = new_date.getMonth(), 142 week_day = new_date.getDay(), 143 month_day = new_date.getDate(), 144 hour = new_date.getHours(), 145 minute = new_date.getMinutes(), 146 sec = new_date.getSeconds(), 147 weekday= [ 148 "Sunday", 149 "Monday", 150 "Tuesday", 151 "Wednesday", 152 "Thursday", 153 "Friday", 154 "Saturday", 155 ], 156 monthNames = [ 157 "January", 158 "February", 159 "March", 160 "April", 161 "May", 162 "June", 163 "July", 164 "August", 165 "September", 166 "October", 167 "November", 168 "December" 169 ]; 170 switch(date_format) { 171 case "ago" : 172 format = ffwd_get_passed_time_popup(time); 173 break; 174 case "F j, Y, g:i a" : 175 format = monthNames[month] + ' ' + month_day + ', ' + year + ', ' + formatAMPM(new_date); 176 break; 177 case "F j, Y" : 178 format = monthNames[month] + ' ' + month_day + ', ' + year; 179 break; 180 case "l, F jS, Y" : 181 format = weekday[week_day] + ', ' + monthNames[month] + ' ' + ordinal_suffix_of(month_day) + ', ' + year; 182 break; 183 case "l, F jS, Y, g:i a" : 184 format = weekday[week_day] + ', ' + monthNames[month] + ' ' + ordinal_suffix_of(month_day) + ', ' + year + ', ' + formatAMPM(new_date); 185 break; 186 case "Y/m/d at g:i a" : 187 format = year + '/' + ((month + 1) > 10 ? (month + 1) : "0" + (month + 1)) + '/' + (month_day > 10 ? month_day : "0" + month_day) + ' at ' + formatAMPM(new_date); 188 break; 189 default: 190 format = ffwd_get_passed_time_popup(time); 191 break; 192 } 193 return format; 194} 195 196function formatAMPM(date) { 197 var hours = date.getHours(), 198 minutes = date.getMinutes(), 199 ampm = hours >= 12 ? 'pm' : 'am'; 200 201 hours = hours % 12; 202 hours = hours ? hours : 12; 203 minutes = minutes < 10 ? '0'+minutes : minutes; 204 var strTime = hours + ':' + minutes + ' ' + ampm; 205 return strTime; 206} 207 208function ordinal_suffix_of(i) { 209 var j = i % 10, 210 k = i % 100; 211 if (j == 1 && k != 11) { 212 return i + "st"; 213 } 214 if (j == 2 && k != 12) { 215 return i + "nd"; 216 } 217 if (j == 3 && k != 13) { 218 return i + "rd"; 219 } 220 return i + "th"; 221} 222 223function ffwd_see_show_hide(string, type, row_type) { 224 string_for_quality = string.replace(/<br\/>/g, "\n"); 225 string = string.replace(/<br\/>/g, " \n "); 226 var new_string = string, 227 hide_text_paragraph = '', 228 length = string_for_quality.length; 229 /*console.log(length); xndir@ ispanerin hatk chareri meja*/ 230 if(row_type == 'events') 231 text_length = (typeof ffwd_options["event_desp_length"] != "undefined") ? ffwd_options["event_desp_length"] : 200; 232 else 233 text_length = (typeof ffwd_options["post_text_length"] != "undefined") ? ffwd_options["post_text_length"] : 200; 234 235 if (length > text_length) { 236 var stringCut = string_for_quality.substr(0, text_length); 237 var last_whitespace_in_string_cut = stringCut.lastIndexOf(" "); 238 last_whitespace_in_string_cut = (last_whitespace_in_string_cut == -1) ? 0 : last_whitespace_in_string_cut; 239 var hide_text_length = length - last_whitespace_in_string_cut; 240 241 stringCut = stringCut.substr(0, last_whitespace_in_string_cut) 242 stringCut = stringCut.replace(/\n/g, " \n "); 243 244 var hide_text = string_for_quality.substr(last_whitespace_in_string_cut, hide_text_length); 245 hide_text = hide_text.replace(/\n/g, " \n "); 246 hide_text_paragraph = ' <span style="display:none" class="ffwd_object_' + type + '_hide" >' + hide_text + ' </span>'; 247 new_string = stringCut + hide_text_paragraph + ' <span class="ffwd_more_dotes" > ... </span> <a href="" class="ffwd_see_more ffwd_see_more_' + type + '">See more</a>'; 248 } 249 return new_string; 250} 251 252function ffwd_fill_tags(message, message_tags) { 253 if(message_tags) 254 var type = message_tags.constructor.name; 255 if(type == "Array") { 256 for(var j=0; j<message_tags.length; j++) { 257 var tag_name = message_tags[j]["name"], 258 tag_id = message_tags[j]["id"]; 259 message = message.replace(tag_name, '<a class="ffwd_message_tag" target="_blank" href="https://www.facebook.com/'+tag_id+'" >'+tag_name+'</a>'); 260 } 261 } 262 else if(type == "Object"){ 263 for(var x in message_tags) { 264 var tag_name = message_tags[x]["0"]["name"], 265 tag_id = message_tags[x]["0"]["id"]; 266 message = message.replace(tag_name, '<a class="ffwd_message_tag" target="_blank" href="https://www.facebook.com/'+tag_id+'" >'+tag_name+'</a>'); 267 } 268 } 269 return message; 270} 271 272 273function ffwd_testBrowser_cssTransitions() { 274 return ffwd_testDom('Transition'); 275} 276 277function ffwd_testBrowser_cssTransforms3d() { 278 return ffwd_testDom('Perspective'); 279} 280 281function ffwd_testDom(prop) { 282 /* Browser vendor CSS prefixes.*/ 283 var browserVendors = ['', '-webkit-', '-moz-', '-ms-', '-o-', '-khtml-']; 284 /* Browser vendor DOM prefixes.*/ 285 var domPrefixes = ['', 'Webkit', 'Moz', 'ms', 'O', 'Khtml']; 286 var i = domPrefixes.length; 287 while (i--) { 288 if (typeof document.body.style[domPrefixes[i] + prop] !== 'undefined') { 289 return true; 290 } 291 } 292 return false;
293} 294 295function ffwd_cube(tz, ntx, nty, nrx, nry, wrx, wry, current_image_class, next_image_class, direction) { 296 /* If browser does not support 3d transforms/CSS transitions.*/ 297 if (!ffwd_testBrowser_cssTransitions()) { 298 return ffwd_fallback(current_image_class, next_image_class, direction); 299 } 300 if (!ffwd_testBrowser_cssTransforms3d()) { 301 return ffwd_fallback3d(current_image_class, next_image_class, direction); 302 } 303 ffwd_trans_in_progress = true; 304 /* Set active thumbnail.*/ 305 jQuery(".ffwd_filmstrip_thumbnail").removeClass("ffwd_thumb_active").addClass("ffwd_thumb_deactive"); 306 jQuery("#ffwd_filmstrip_thumbnail_" + ffwd_current_key).removeClass("ffwd_thumb_deactive").addClass("ffwd_thumb_active"); 307 jQuery(".ffwd_slide_bg").css('perspective', 1000); 308 jQuery(current_image_class).css({ 309 transform : 'translateZ(' + tz + 'px)', 310 backfaceVisibility : 'hidden' 311 }); 312 jQuery(next_image_class).css({ 313 opacity : 1, 314 filter: 'Alpha(opacity=100)', 315 backfaceVisibility : 'hidden', 316 transform : 'translateY(' + nty + 'px) translateX(' + ntx + 'px) rotateY('+ nry +'deg) rotateX('+ nrx +'deg)' 317 }); 318 jQuery(".ffwd_slider").css({ 319 transform: 'translateZ(-' + tz + 'px)', 320 transformStyle: 'preserve-3d' 321 }); 322 /* Execution steps.*/ 323 setTimeout(function () { 324 jQuery(".ffwd_slider").css({ 325 transition: 'all ' + ffwd_transition_duration + 'ms ease-in-out', 326 transform: 'translateZ(-' + tz + 'px) rotateX('+ wrx +'deg) rotateY('+ wry +'deg)' 327 }); 328 }, 20); 329 /* After transition.*/ 330 jQuery(".ffwd_slider").one('webkitTransitionEnd transitionend otransitionend oTransitionEnd mstransitionend', jQuery.proxy(ffwd_after_trans)); 331 function ffwd_after_trans() { 332 jQuery(current_image_class).removeAttr('style'); 333 jQuery(next_image_class).removeAttr('style'); 334 jQuery(".ffwd_slider").removeAttr('style'); 335 jQuery(current_image_class).css({'opacity' : 0, filter: 'Alpha(opacity=0)', 'z-index': 1}); 336 jQuery(next_image_class).css({'opacity' : 1, filter: 'Alpha(opacity=100)', 'z-index' : 2}); 337 338 ffwd_trans_in_progress = false; 339 jQuery(current_image_class).html(''); 340 341 /*First check main objects*/ 342 if (typeof ffwd_event_stack !== 'undefined' && ffwd_event_stack.length > 0) { 343 ffwd_event_stack_for_attachments = []; 344 key = ffwd_event_stack[0].split("-"); 345 ffwd_event_stack.shift(); 346 ffwd_change_image(key[0], key[1], data, true); 347 } 348 /*Then sub objects*/ 349 if (typeof ffwd_event_stack_for_attachments !== 'undefined' && ffwd_event_stack_for_attachments.length > 0) { 350 var object = ffwd_event_stack_for_attachments[0]; 351 ffwd_event_stack_for_attachments.shift(); 352 ffwd_change_subattachment(object); 353 } 354 } 355} 356function ffwd_cubeH(current_image_class, next_image_class, direction) { 357 /* Set to half of image width.*/ 358 var dimension = jQuery(current_image_class).width() / 2; 359 if (direction == 'right') { 360 ffwd_cube(dimension, dimension, 0, 0, 90, 0, -90, current_image_class, next_image_class, direction); 361 } 362 else if (direction == 'left') { 363 ffwd_cube(dimension, -dimension, 0, 0, -90, 0, 90, current_image_class, next_image_class, direction); 364 } 365} 366function ffwd_cubeV(current_image_class, next_image_class, direction) { 367 /* Set to half of image height.*/ 368 var dimension = jQuery(current_image_class).height() / 2; 369 /* If next slide.*/ 370 if (direction == 'right') { 371 ffwd_cube(dimension, 0, -dimension, 90, 0, -90, 0, current_image_class, next_image_class, direction); 372 } 373 else if (direction == 'left') { 374 ffwd_cube(dimension, 0, dimension, -90, 0, 90, 0, current_image_class, next_image_class, direction); 375 } 376} 377/* For browsers that does not support transitions.*/ 378function ffwd_fallback(current_image_class, next_image_class, direction) { 379 ffwd_fade(current_image_class, next_image_class, direction); 380} 381/* For browsers that support transitions, but not 3d transforms (only used if primary transition makes use of 3d-transforms).*/ 382function ffwd_fallback3d(current_image_class, next_image_class, direction) { 383 ffwd_sliceV(current_image_class, next_image_class, direction); 384} 385function ffwd_none(current_image_class, next_image_class, direction) { 386 jQuery(current_image_class).css({'opacity' : 0, 'z-index': 1}); 387 jQuery(next_image_class).css({'opacity' : 1, 'z-index' : 2}); 388 /* Set active thumbnail.*/ 389 jQuery(".ffwd_filmstrip_thumbnail").removeClass("ffwd_thumb_active").addClass("ffwd_thumb_deactive"); 390 jQuery("#ffwd_filmstrip_thumbnail_" + ffwd_current_key).removeClass("ffwd_thumb_deactive").addClass("ffwd_thumb_active"); 391 ffwd_trans_in_progress = false;
392 jQuery(current_image_class).html(''); 393} 394function ffwd_fade(current_image_class, next_image_class, direction) { 395 /* Set active thumbnail.*/ 396 jQuery(".ffwd_filmstrip_thumbnail").removeClass("ffwd_thumb_active").addClass("ffwd_thumb_deactive"); 397 jQuery("#ffwd_filmstrip_thumbnail_" + ffwd_current_key).removeClass("ffwd_thumb_deactive").addClass("ffwd_thumb_active"); 398 if (ffwd_testBrowser_cssTransitions()) { 399 jQuery(next_image_class).css('transition', 'opacity ' + ffwd_transition_duration + 'ms linear'); 400 jQuery(current_image_class).css({'opacity' : 0, 'z-index': 1}); 401 jQuery(next_image_class).css({'opacity' : 1, 'z-index' : 2}); 402 } 403 else { 404 jQuery(current_image_class).animate({'opacity' : 0, 'z-index' : 1}, ffwd_transition_duration); 405 jQuery(next_image_class).animate({ 406 'opacity' : 1, 407 'z-index': 2 408 }, { 409 duration: ffwd_transition_duration, 410 complete: function () { 411 412 ffwd_trans_in_progress = false; 413 jQuery(current_image_class).html(''); 414 } 415 }); 416 /* For IE.*/ 417 jQuery(current_image_class).fadeTo(ffwd_transition_duration, 0); 418 jQuery(next_image_class).fadeTo(ffwd_transition_duration, 1); 419 } 420} 421function ffwd_grid(cols, rows, ro, tx, ty, sc, op, current_image_class, next_image_class, direction) { 422 /* If browser does not support CSS transitions.*/ 423 if (!ffwd_testBrowser_cssTransitions()) { 424 return ffwd_fallback(current_image_class, next_image_class, direction); 425 } 426 ffwd_trans_in_progress = true; 427 /* Set active thumbnail.*/ 428 jQuery(".ffwd_filmstrip_thumbnail").removeClass("ffwd_thumb_active").addClass("ffwd_thumb_deactive"); 429 jQuery("#ffwd_filmstrip_thumbnail_" + ffwd_current_key).removeClass("ffwd_thumb_deactive").addClass("ffwd_thumb_active"); 430 /* The time (in ms) added to/subtracted from the delay total for each new gridlet.*/ 431 var count = (ffwd_transition_duration) / (cols + rows); 432 /* Gridlet creator (divisions of the image grid, positioned with background-images to replicate the look of an entire slide image when assembled)*/ 433 function ffwd_gridlet(width, height, top, img_top, left, img_left, src, imgWidth, imgHeight, c, r) { 434 var delay = (c + r) * count; 435 /* Return a gridlet elem with styles for specific transition.*/ 436 return jQuery('<div class="ffwd_gridlet" />').css({ 437 width : width, 438 height : height, 439 top : top, 440 left : left, 441 backgroundImage : 'url("' + src + '")', 442 backgroundColor: jQuery(".spider_popup_wrap").css("background-color"), 443 /*backgroundColor: 'rgba(0, 0, 0, 0)',*/ 444 backgroundRepeat: 'no-repeat', 445 backgroundPosition : img_left + 'px ' + img_top + 'px', 446 backgroundSize : imgWidth + 'px ' + imgHeight + 'px', 447 transition : 'all ' + ffwd_transition_duration + 'ms ease-in-out ' + delay + 'ms', 448 transform : 'none' 449 }); 450 } 451 /* Get the current slide's image.*/ 452 var cur_img = jQuery(current_image_class).find('img'); 453 /* Create a grid to hold the gridlets.*/ 454 var grid = jQuery('<div />').addClass('ffwd_grid'); 455 /* Prepend the grid to the next slide (i.e. so it's above the slide image).*/ 456 jQuery(current_image_class).prepend(grid); 457 /* Vars to calculate positioning/size of gridlets.*/ 458 var cont = jQuery(".ffwd_slide_bg"); 459 var imgWidth = cur_img.width(); 460 var imgHeight = cur_img.height(); 461 var contWidth = cont.width(), 462 contHeight = cont.height(),
463 colWidth = Math.floor(contWidth / cols), 464 rowHeight = Math.floor(contHeight / rows), 465 colRemainder = contWidth - (cols * colWidth), 466 colAdd = Math.ceil(colRemainder / cols), 467 rowRemainder = contHeight - (rows * rowHeight), 468 rowAdd = Math.ceil(rowRemainder / rows), 469 leftDist = 0, 470 img_leftDist = Math.ceil((jQuery(".ffwd_slide_bg").width() - cur_img.width()) / 2); 471 var imgSrc = typeof cur_img.attr('src')=='undefined' ? '' :cur_img.attr('src'); 472 /* tx/ty args can be passed as 'auto'/'min-auto' (meaning use slide width/height or negative slide width/height).*/ 473 tx = tx === 'auto' ? contWidth : tx; 474 tx = tx === 'min-auto' ? - contWidth : tx; 475 ty = ty === 'auto' ? contHeight : ty; 476 ty = ty === 'min-auto' ? - contHeight : ty; 477 /* Loop through cols.*/ 478 for (var i = 0; i < cols; i++) { 479 var topDist = 0, 480 img_topDst = Math.floor((jQuery(".ffwd_slide_bg").height() - cur_img.height()) / 2), 481 newColWidth = colWidth; 482 /* If imgWidth (px) does not divide cleanly into the specified number of cols, adjust individual col widths to create correct total.*/ 483 if (colRemainder > 0) { 484 var add = colRemainder >= colAdd ? colAdd : colRemainder; 485 newColWidth += add; 486 colRemainder -= add; 487 } 488 /* Nested loop to create row gridlets for each col.*/ 489 for (var j = 0; j < rows; j++) { 490 var newRowHeight = rowHeight, 491 newRowRemainder = rowRemainder; 492 /* If contHeight (px) does not divide cleanly into the specified number of rows, adju
492st individual row heights to create correct total.*/ 493 if (newRowRemainder > 0) { 494 add = newRowRemainder >= rowAdd ? rowAdd : rowRemainder; 495 newRowHeight += add; 496 newRowRemainder -= add; 497 } 498 /* Create & append gridlet to grid.*/ 499 grid.append(ffwd_gridlet(newColWidth, newRowHeight, topDist, img_topDst, leftDist, img_leftDist, imgSrc, imgWidth, imgHeight, i, j)); 500 topDist += newRowHeight; 501 img_topDst -= newRowHeight; 502 } 503 img_leftDist -= newColWidth; 504 leftDist += newColWidth; 505 } 506 /* Set event listener on last gridlet to finish transitioning.*/ 507 var last_gridlet = grid.children().last(); 508 /* Show grid & hide the image it replaces.*/ 509 grid.show(); 510 cur_img.css('opacity', 0); 511 /* Add identifying classes to corner gridlets (useful if applying border radius).*/ 512 grid.children().first().addClass('rs-top-left'); 513 grid.children().last().addClass('rs-bottom-right'); 514 grid.children().eq(rows - 1).addClass('rs-bottom-left'); 515 grid.children().eq(- rows).addClass('rs-top-right'); 516 /* Execution steps.*/ 517 setTimeout(function () { 518 grid.children().css({ 519 opacity: op, 520 transform: 'rotate('+ ro +'deg) translateX('+ tx +'px) translateY('+ ty +'px) scale('+ sc +')' 521 }); 522 }, 30); 523 jQuery(next_image_class).css('opacity', 1); 524 /* After transition.*/ 525 jQuery(last_gridlet).one('webkitTransitionEnd transitionend otransitionend oTransitionEnd mstransitionend', jQuery.proxy(ffwd_after_trans)); 526 function ffwd_after_trans() { 527 528 /*console.log('ffwd_after_transssss');*/ 529 530 jQuery(current_image_class).css({'opacity' : 0, 'z-index': 1}); 531 jQuery(next_image_class).css({'opacity' : 1, 'z-index' : 2}); 532 cur_img.css('opacity', 1); 533 grid.remove(); 534 ffwd_trans_in_progress = false; 535 jQuery(current_image_class).html(''); 536 537 /*First check main objects*/ 538 if (typeof ffwd_event_stack !== 'undefined' && ffwd_event_stack.length > 0) { 539 /*console.log('gag');*/ 540 ffwd_event_stack_for_attachments = []; 541 key = ffwd_event_stack[0].split("-"); 542 ffwd_event_stack.shift(); 543 ffwd_change_image(key[0], key[1], data, true); 544 } 545 /*Then sub objects*/ 546 if (typeof ffwd_event_stack_for_attachments !== 'undefined' && ffwd_event_stack_for_attachments.length > 0) { 547 var object = ffwd_event_stack_for_attachments[0]; 548 ffwd_event_stack_for_attachments.shift(); 549 ffwd_change_subattachment(object); 550 } 551 } 552} 553function ffwd_sliceH(current_image_class, next_image_class, direction) { 554 if (direction == 'right') { 555 var translateX = 'min-auto'; 556 } 557 else if (direction == 'left') { 558 var translateX = 'auto'; 559 } 560 ffwd_grid(1, 8, 0, translateX, 0, 1, 0, current_image_class, next_image_class, direction); 561} 562function ffwd_sliceV(current_image_class, next_image_class, direction) { 563 if (direction == 'right') { 564 var translateY = 'min-auto'; 565 } 566 else if (direction == 'left') { 567 var translateY = 'auto'; 568 } 569 ffwd_grid(10, 1, 0, 0, translateY, 1, 0, current_image_class, next_image_class, direction); 570} 571function ffwd_slideV(current_image_class, next_image_class, direction) { 572 if (direction == 'right') { 573 var translateY = 'auto'; 574 } 575 else if (direction == 'left') { 576 var translateY = 'min-auto'; 577 } 578 ffwd_grid(1, 1, 0, 0, translateY, 1, 1, current_image_class, next_image_class, direction); 579} 580function ffwd_slideH(current_image_class, next_image_class, direction) { 581 if (direction == 'right') { 582 var translateX = 'min-auto'; 583 } 584 else if (direction == 'left') { 585 var translateX = 'auto'; 586 } 587 ffwd_grid(1, 1, 0, translateX, 0, 1, 1, current_image_class, next_image_class, direction); 588} 589function ffwd_scaleOut(current_image_class, next_image_class, direction) { 590 ffwd_grid(1, 1, 0, 0, 0, 1.5, 0, current_image_class, next_image_class, direction); 591} 592function ffwd_scaleIn(current_image_class, next_image_class, direction) { 593 ffwd_grid(1, 1, 0, 0, 0, 0.5, 0, current_image_class, next_image_class, direction); 594} 595function ffwd_blockScale(current_image_class, next_image_class, direction) { 596 ffwd_grid(8, 6, 0, 0, 0, .6, 0, current_image_class, next_image_class, direction); 597} 598function ffwd_kaleidoscope(current_image_class, next_image_class, direction) { 599 ffwd_grid(10, 8, 0, 0, 0, 1, 0, current_image_class, next_image_class, direction); 600} 601function ffwd_fan(current_image_class, next_image_class, direction) { 602 if (direction == 'right') { 603 var rotate = 45; 604 var translateX = 100; 605 } 606 else if (direction == 'left') { 607 var rotate = -45; 608 var translateX = -100; 609 }
610 ffwd_grid(1, 10, rotate, translateX, 0, 1, 0, current_image_class, next_image_class, direction); 611} 612function ffwd_blindV(current_image_class, next_image_class, direction) { 613 ffwd_grid(1, 8, 0, 0, 0, .7, 0, current_image_class, next_image_class); 614} 615function ffwd_blindH(current_image_class, next_image_class, direction) { 616 ffwd_grid(10, 1, 0, 0, 0, .7, 0, current_image_class, next_image_class); 617} 618function ffwd_random(current_image_class, next_image_class, direction) { 619 var anims = ['sliceH', 'sliceV', 'slideH', 'slideV', 'scaleOut', 'scaleIn', 'blockScale', 'kaleidoscope', 'fan', 'blindH', 'blindV']; 620 /* Pick a random transition from the anims array.*/ 621 this["ffwd_" + anims[Math.floor(Math.random() * anims.length)]](current_image_class, next_image_class, direction); 622} 623function ffwd_reset_zoom() { 624 var isMobile = (/android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(navigator.userAgent.toLowerCase())); 625 var viewportmeta = document.querySelector('meta[name="viewport"]'); 626 if (isMobile && viewportmeta) { 627 viewportmeta.content = 'width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=0'; 628 } 629} 630 631/*Show hide subattachments cont*/ 632function show_hide_sub_attachments(pos) { 633 /*Click from button*/ 634 if(!pos) { 635 pos = (jQuery('.ffwd_sub_attachmenst_cont').css('top') == '0px') ? '-58px' : '0px'; 636 } 637 jQuery('.ffwd_sub_attachmenst_cont').animate({ 638 top: pos, 639 }, 250, "linear", function() { 640 641 }); 642} 643 644/* Change object info*/ 645function ffwd_change_info(key) { 646 var object = data[key], 647 name = jQuery('<div />').html(object['name']).text(), 648 link = object['link'], 649 message = ffwd_see_show_hide(object['message'], 'message', object['type']), 650 message_tags = object['message_tags'], 651 description = ffwd_see_show_hide(object['description'], 'description', object['type']), 652 653 time = object['created_time'], 654 place_name = '', 655 place_id, 656 class_name = (object["type"] != "events") ? ".ffwd_popup_from_time_post" : ".ffwd_popup_from_time_event"; 657 658 message = ffwd_fill_hashtags(message); 659 message = ffwd_fill_tags(message, message_tags); 660 description = ffwd_fill_hashtags(description); 661 662 ffwd_fill_story_author_place(key); 663 jQuery('.ffwd_object_name').html(name).attr('href', link); 664 jQuery('.ffwd_object_messages').html(message); 665 jQuery('.ffwd_object_description').html(description); 666 jQuery(class_name + " span").html(ffwd_time(object)); 667} 668 669/*Function for fill hashtags*/ 670function ffwd_fill_hashtags(str) { 671 str = str.replace(/ \n /g, " <br> "); 672 str = str.split(' '); 673 for(var i=0; i<str.length; i++) { 674 if(str[i].indexOf('#') !== -1) { 675 var hashtag = str[i].replace('#', '<a class="ffwd_hashtag" target="_blank" href="https://www.facebook.com/hashtag/'); 676 var word = str[i].split('#'); 677 word = '#' + word[1]; 678 hashtag += '">' + word + '</a>'; 679 str[i] = hashtag; 680 } 681 } 682 str = str.join(' '); 683 return str; 684} 685 686/*See less see more*/ 687function ffwd_see_less_more(that, more_less, type) { 688 var display = (more_less == 'more') ? 'inline' : 'none', 689 display_dotes = (more_less == 'more') ? 'none' : 'inline', 690 less_more = (more_less == 'more') ? 'less' : 'more'; 691 692 that.parent().parent().find('.ffwd_object_'+type+'_hide').css('display', display); 693 that.html('See ' + less_more).removeClass('ffwd_see_' + more_less + '_' + type).addClass('ffwd_see_' + less_more + '_' + type); 694 that.parent().find('.ffwd_more_dotes').css('display', display_dotes); 695} 696 697/*Function for comments and likes cont*/ 698function ffwd_fill_likes_comments(key) 699{ 700 if(ffwd_content_type == "specific") 701 { 702 var url_for_cur_id = popup_graph_url.replace('{FB_ID}', data[key]['object_id']); 703 /*For likes*/ 704 705 var graph_url_for_likes = url_for_cur_id.replace('{EDGE}', ''); 706 graph_url_for_likes = graph_url_for_likes.replace('{FIELDS}', 'fields=likes.summary(true){id,name},comments.summary(true){created_time,from,like_count,message,comment_count}&'); 707 graph_url_for_likes = graph_url_for_likes.replace('{OTHER}', 'summary=true'); 708 jQuery.getJSON(graph_url_for_likes, function(result) { 709 gallery_box_comments(result, key) 710 }); 711 return; 712 } 713 714 715 var url_for_cur_id = popup_graph_url.replace('{FB_ID}', data[key]['object_id']); 716 /*For likes*/ 717 var graph_url_for_likes = url_for_cur_id.replace('{EDGE}', 'likes'); 718 graph_url_for_likes = graph_url_for_likes.replace('{FIELDS}', 'fields=id,name&'); 719 graph_url_for_likes = graph_url_for_likes.replace('{OTHER}', 'summary=true'); 720 /*For comments*/ 721 var graph_url_for_comments = url_for_cur_id.replace('{EDGE}', 'comments'); 722 graph_url_for_comments = graph_url_for_comments.replace('{FIELDS}', 'fields=created_time,from,like_count,message,comment_count&'); 723 graph_url_for_comments = graph_url_for_comments.replace('{OTHER}', 'summary=true&filter='+ffwd_options["comments_filter"]+'&order='+ffwd_options["comments_order"]+'&limit=60'); 724 /*console.log(graph_url_for_comments)*/ 725 /*For shares*/ 726 var graph_url_for_shares = url_for_cur_id.replace('{EDGE}', ''); 727 graph_url_for_shares = graph_url_for_shares.replace('{FIELDS}', 'fields=shares&'); 728 graph_url_for_shares = graph_url_for_shares.replace('{OTHER}', ''); 729 jQuery.getJSON(graph_url_for_likes, function(result) { 730 var likes_count = (typeof result['summary'] != 'undefined') ? parseInt(result['summary']['total_count']) : 0; 731 jQuery('#ffwd_likes span').html(likes_count); 732 /*if(likes_count >= 3) { 733 var likes_some_names = '<div class="ffwd_likes_name_cont"> <a class="ffwd_likes_name" href="https://www.facebook.com/'+result['data'][0]['id']+'" target="_blank">' + result['data'][0]['name'] + ' , </a><a class="ffwd_likes_name" href="https://www.facebook.com/'+result['data'][1]['id']+'" target="_blank">' + result['data'][1]['name'] +'</a></div>', 734 likes_count_last_part = '<div class="ffwd_likes_count_last_part" > and ' + (likes_count - 2) +' others like this </div>'; 735 } 736 else if(likes_count == 2 ) { 737 var likes_some_names = '<div> <a class="ffwd_likes_name" href="https://www.facebook.com/'+result['data'][0]['id']+'" target="_blank">' + result['data'][0]['name'] + ' , </a> , <a class="ffwd_likes_name" href="https://www.facebook.com/'+result['data'][1]['id']+'" target="_blank">' + result['data'][1]['name'] +'</a></div>', 738 likes_count_last_part = ''; 739 } 740 else if(likes_count == 1 ) { 741 var likes_some_names = '<div> <a class="ffwd_likes_name" href="https://www.facebook.com/'+result['data'][0]['id']+'" target="_blank">' + result['data'][0]['name'] + '</a></div>', 742 likes_count_last_part = ''; 743 } 744 else { 745 var likes_some_names = '', 746 likes_count_last_part = ''; 747 }*/ 748 749 var likes_some_names = '',
750 likes_count_last_part = ''; 751 var likes_names_count = '<div class="ffwd_likes_names" > '+likes_some_names+likes_count_last_part+' </div><div style="clear:both" ></div>'; 752 if(likes_count > 0) 753 jQuery('#ffwd_likes_names_count').html(likes_names_count).css("display", "block"); 754 else 755 jQuery('#ffwd_likes_names_count').css("display", "none"); 756 }); 757 /* For shares */ 758 if(ffwd_content_type == "timeline") { 759 var shares_count = (typeof data[key]['shares'] != 'undefined') ? parseInt(data[key]['count']) : '0'; 760 jQuery('#ffwd_shares span').html(shares_count); 761 } 762 /* For comments */ 763 764 var total_count = (data[key]['comments']['data'].length < 25) ? data[key]['comments']['data'].length : data[key]['comments']['summary']['total_count']; 765 jQuery('#ffwd_comments_count span').html(total_count); 766 var more_comments = false; 767 jQuery('#ffwd_comments_content span').html(''); 768 for(var i=0, j=1, z=0; i<data[key]['comments']['data'].length; i++,j++) { 769 var display = 'display:block', 770 comment_id = data[key]['comments']['data'][i]['id']; 771 if(j > 4) { 772 display = 'display:none'; 773 more_comments = true; 774 z++; 775 } 776 777/* 778 var url_for_cur_id_comm_user_pic = popup_graph_url.replace('{FB_ID}', data[key]['comments']['data'][i]['from']['id']); 779 url_for_cur_id_comm_user_pic = url_for_cur_id_comm_user_pic.replace('{EDGE}', ''); 780 url_for_cur_id_comm_user_pic = url_for_cur_id_comm_user_pic.replace('{FIELDS}', '&fields=picture&'); 781 url_for_cur_id_comm_user_pic = url_for_cur_id_comm_user_pic.replace('{OTHER}', ''); 782 783*/ 784 785 //var comment_author_pic = '<div style="float:left" class="ffwd_comment_author_pic" > <img class="user_'+data[key]['comments']['data'][i]['from']['id']+'" style="width:32px;height:32px" src="https://graph.facebook.com/'+data[key]['comments']['data'][i]['from']['id']+'/picture" > </div>', 786 var comment_author_pic = '<span></span>', 787 //comment_author_name = '<a class="ffwd_comment_author_name" href="https://www.facebook.com/'+data[key]['comments']['data'][i]['from']['id']+'" target="_blank"> '+data[key]['comments']['data'][i]['from']['name']+' </a>', 788 comment_author_name = '<span></span>', 789 comment_message = '<span class="ffwd_comment_message" > '+data[key]['comments']['data'][i]['message']+' </span>', 790 comment_date = '<span class="ffwd_comment_date" ><i class="ffwd ffwd-time"></i><span> '+ffwd_get_passed_time_popup(data[key]['comments']['data'][i]['created_time'])+'</span></span>', 791 comment_likes_count = '<span class="ffwd_comment_likes_count"><i class="ffwd ffwd-like"></i><span> '+data[key]['comments']['data'][i]['like_count']+' </span></span>', 792 comment_date_likes = '<div class="ffwd_comment_date_likes">'+ comment_date + comment_likes_count + '</div>', 793 comment_replies_cont = (ffwd_options["comments_filter"] == "toplevel" && ffwd_options["comments_replies"] == "1" && data[key]['comments']['data'][i]['comment_count'] > 0) ? '<div class="ffwd_comment_replies"><div id="ffwd_comment_replies_popup_label_' + data[key]['comments']['data'][i]['id']+'" class="ffwd_comment_replies_label">'+data[key]['comments']['data'][i]['comment_count']+' Reply</div><div class="ffwd_comment_replies_content"></div></div>' : '', 794 comment_div_cont = '<div class="ffwd_comment_content" >'+comment_author_name+comment_message+comment_date_likes+comment_replies_cont+'<div style="clear:both"></div></div>', 795 comment = '<div id="ffwd_single_comment_'+comment_id+'" style="'+display+'" class="ffwd_single_comment">' + comment_author_pic + comment_div_cont + '<div style="clear:both" > </div></div>'; 796 jQuery('#ffwd_comments_content').append(comment); 797 /*jQuery.getJSON(url_for_cur_id_comm_user_pic, function(result) { 798 jQuery('.user_'+result['id']+'').attr('src', result['picture']['data']['url']); 799 });*/ 800 if(ffwd_options["comments_filter"] == "toplevel" && ffwd_options["comments_replies"] == "1") 801 { 802 803 804 (function (i) { 805 806 jQuery('#ffwd_comment_replies_popup_label_' + data[key]['comments']['data'][i]['id']).bind("click", function () { 807 808 ffwd_get_comments_replies_popup(data[key]['comments']['data'][i]['id'], popup_graph_url); 809 }) 810 }(i)) 811 812 } 813 } 814 if(more_comments) { 815 jQuery('#ffwd_comments_content').append('<div class="ffwd_view_more_comments_cont"> <a href="#" class="ffwd_view_more_comments" more_count="'+z+'"> <span> View '+z+' more comments </span> <a> </div>'); 816 } 817 ; 818} 819var gallery_box_comments_key = null; 820function gallery_box_comments(result, key) { 821 var likes_count = (typeof result['likes']['summary'] != 'undefined') ? parseInt(result['likes']['summary']['total_count']) : 0; 822 jQuery('#ffwd_likes span').html(likes_count); 823 if(likes_count >= 3) { 824 var likes_some_names = '<div class="ffwd_likes_name_cont"> <a class="ffwd_likes_name" href="https://www.facebook.com/'+result['likes']['data'][0]['id']+'" target="_blank">' + result['likes']['data'][0]['name'] + ' , </a><a class="ffwd_likes_name" href="https://www.facebook.com/'+result['likes']['data'][1]['id']+'" target="_blank">' + result['likes']['data'][1]['name'] +'</a></div>',
825 likes_count_last_part = '<div class="ffwd_likes_count_last_part" > and ' + (likes_count - 2) +' others like this </div>'; 826 } 827 else if(likes_count == 2 ) { 828 var likes_some_names = '<div> <a class="ffwd_likes_name" href="https://www.facebook.com/'+result['likes']['data'][0]['id']+'" target="_blank">' + result['likes']['data'][0]['name'] + ' , </a> , <a class="ffwd_likes_name" href="https://www.facebook.com/'+result['likes']['data'][1]['id']+'" target="_blank">' + result['likes']['data'][1]['name'] +'</a></div>', 829 likes_count_last_part = ''; 830 } 831 else if(likes_count == 1 ) { 832 var likes_some_names = '<div> <a class="ffwd_likes_name" href="https://www.facebook.com/'+result['likes']['data'][0]['id']+'" target="_blank">' + result['likes']['data'][0]['name'] + '</a></div>', 833 likes_count_last_part = ''; 834 } 835 else { 836 var likes_some_names = '', 837 likes_count_last_part = ''; 838 } 839 var likes_names_count = '<div class="ffwd_likes_names" > '+likes_some_names+likes_count_last_part+' </div><div style="clear:both" ></div>'; 840 if(likes_count > 0) 841 jQuery('#ffwd_likes_names_count').html(likes_names_count).css("display", "block"); 842 else 843 jQuery('#ffwd_likes_names_count').css("display", "none"); 844 var total_count = result['comments']['summary']['total_count']; 845 846 var more_comments = false; 847 jQuery('#ffwd_comments_count span').html(total_count); 848 if(gallery_box_comments_key !== null && gallery_box_comments_key !== result.id){ 849 jQuery('#ffwd_comments_content').html(''); 850 } 851 gallery_box_comments_key = result.id; 852 for(var i=0, j=1, z=0; i<result['comments']['data'].length; i++,j++) { 853 var display = 'display:block', 854 comment_id = result['comments']['data'][i]['id']; 855 if(j > 4) { 856 //display = 'display:none'; 857 more_comments = true; 858 z++; 859 } 860 861 /* 862 var url_for_cur_id_comm_user_pic = popup_graph_url.replace('{FB_ID}', result['comments']['data'][i]['from']['id']); 863 url_for_cur_id_comm_user_pic = url_for_cur_id_comm_user_pic.replace('{EDGE}', ''); 864 url_for_cur_id_comm_user_pic = url_for_cur_id_comm_user_pic.replace('{FIELDS}', '&fields=picture&'); 865 url_for_cur_id_comm_user_pic = url_for_cur_id_comm_user_pic.replace('{OTHER}', ''); 866 867 */ 868 869 //var comment_author_pic = '<div style="float:left" class="ffwd_comment_author_pic" > <img class="user_'+result['comments']['data'][i]['from']['id']+'" style="width:32px;height:32px" src="https://graph.facebook.com/'+result['comments']['data'][i]['from']['id']+'/picture" > </div>', 870 var comment_author_pic = '<span></span>', 871 comment_author_name = '<span></span>', 872 //comment_author_name = '<a class="ffwd_comment_author_name" href="https://www.facebook.com/'+result['comments']['data'][i]['from']['id']+'" target="_blank"> '+result['comments']['data'][i]['from']['name']+' </a>', 873 comment_message = '<span class="ffwd_comment_message" > '+result['comments']['data'][i]['message']+' </span>', 874 comment_date = '<span class="ffwd_comment_date" ><i class="ffwd ffwd-time"></i><span> '+ffwd_get_passed_time_popup(result['comments']['data'][i]['created_time'])+'</span></span>', 875 comment_likes_count = '<span class="ffwd_comment_likes_count"><i class="ffwd ffwd-like"></i><span> '+result['comments']['data'][i]['like_count']+' </span></span>', 876 comment_date_likes = '<div class="ffwd_comment_date_likes">'+ comment_date + comment_likes_count + '</div>', 877 comment_replies_cont = (ffwd_options["comments_filter"] == "toplevel" && ffwd_options["comments_replies"] == "1" && result['comments']['data'][i]['comment_count'] > 0) ? '<div class="ffwd_comment_replies"><div id="ffwd_comment_replies_popup_label_' + result['comments']['data'][i]['id']+'" class="ffwd_comment_replies_label">'+result['comments']['data'][i]['comment_count']+' Reply</div><div class="ffwd_comment_replies_content"></div></div>' : '', 878 comment_div_cont = '<div class="ffwd_comment_content" >'+comment_author_name+comment_message+comment_date_likes+comment_replies_cont+'<div style="clear:both"></div></div>', 879 comment = '<div id="ffwd_single_comment_'+comment_id+'" style="'+display+'" class="ffwd_single_comment">' + comment_author_pic + comment_div_cont + '<div style="clear:both" > </div></div>'; 880 jQuery('#ffwd_comments_content').append(comment); 881 /*jQuery.getJSON(url_for_cur_id_comm_user_pic, function(result) { 882 jQuery('.user_'+result['id']+'').attr('src', result['picture']['data']['url']); 883 });*/ 884 if(ffwd_options["comments_filter"] == "toplevel" && ffwd_options["comments_replies"] == "1") 885 { 886 887 888 (function (i) { 889 890 jQuery('#ffwd_comment_replies_popup_label_' + result['comments']['data'][i]['id']).bind("click", function () { 891 892 ffwd_get_comments_replies_popup(result['comments']['data'][i]['id'], popup_graph_url); 893 }) 894 }(i)) 895 896 } 897 } 898 var id = 1; 899 var ffwd = 1; 900 jQuery('#ffwd_comments_content .ffwd_load_more').remove(); 901 if(typeof result['comments'].paging !== "undefined" && typeof result['comments'].paging.next !== "undefined"){ 902 jQuery('#ffwd_comments_content').append('<span data-ffwd_params="" data-fanc="gallery_box_comments" data-id="'+result.id+'" data-links="'+result['likes']+'" data-next_url = "'+result['comments'].paging.next+'" class="ffwd_load_more">Load more</span>') 903 }; 904 905 906 907} 908 909function ffwd_get_comments_replies_popup(comment_id,popup_graph_url) { 910 var url_for_cur_id_comm_replies = popup_graph_url.replace('{FB_ID}', comment_id); 911 url_for_cur_id_comm_replies = url_for_cur_id_comm_replies.replace('{EDGE}', 'comments'); 912 url_for_cur_id_comm_replies = url_for_cur_id_comm_replies.replace('{FIELDS}', 'fields=parent,created_time,from,like_count,message&'); 913 url_for_cur_id_comm_replies = url_for_cur_id_comm_replies.replace('{OTHER}', ''); 914 jQuery.getJSON(url_for_cur_id_comm_replies, function(result) { 915 for (var k = 0; k < result['data'].length; k++) { 916 var parent_comm_id = comment_id, 917 comment_reply_id = result['data'][k]["id"]; 918 919 var url_for_cur_id_comm_rep_user_pic = popup_graph_url.replace('{FB_ID}', result['data'][k]['from']['id']); 920 url_for_cur_id_comm_rep_user_pic = url_for_cur_id_comm_rep_user_pic.replace('{EDGE}', ''); 921 url_for_cur_id_comm_rep_user_pic = url_for_cur_id_comm_rep_user_pic.replace('{FIELDS}', 'fields=picture&'); 922 url_for_cur_id_comm_rep_user_pic = url_for_cur_id_comm_rep_user_pic.replace('{OTHER}', ''); 923 924 var comment_reply_author_pic = '<div class="ffwd_comment_reply_author_pic" style="float:left" > <img class="reply_user_' + result['data'][k]['from']['id'] + '" style="width:25px;height:25px" src="https://graph.facebook.com/' + result['data'][k]['from']['id'] + '/picture" > </div>', 925 comment_reply_author_name = '<a class="ffwd_comment_reply_author_name" href="https://www.facebook.com/' + result['data'][k]['from']['id'] + '" > ' + result['data'][k]['from']['name'] + ' </a>', 926 comment_reply_message = '<span class="ffwd_comment_reply_message" > ' + result['data'][k]['message'] + ' </span>', 927 comment_reply_date = '<span class="ffwd_comment_reply_date" > ' + ffwd_get_passed_time_popup(result['data'][k]['created_time']) + '</span>', 928 comment_reply_likes_count = '<span class="ffwd_comment_reply_likes_count" > ' + result['data'][k]['like_count'] + ' </span>', 929 comment_reply_date_likes = '<div class="ffwd_comment_reply_date_likes">' + comment_reply_date + comment_reply_likes_count + '</div>', 930 comment_reply_div_cont = '<div class="ffwd_comment_reply_content" >' + comment_reply_author_name + comment_reply_message + comment_reply_date_likes + '<div style="clear:both"></div></div>', 931 comment_reply = '<div class="ffwd_comment_reply" id="ffwd_comment_reply_' + comment_reply_id + '" >' + comment_reply_author_pic + comment_reply_div_cont + '<div style="clear:both" > </div></div>'; 932 933 jQuery('#ffwd_single_comment_' + parent_comm_id + ' .ffwd_comment_replies_content').append(comment_reply
933); 934 /*jQuery.getJSON(url_for_cur_id_comm_rep_user_pic, function(result) { 935 jQuery('.reply_user_'+result['id']+'').attr('src', result['picture']['data']['url']); 936 });*/ 937 } 938 }) 939 940}
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.