1jQuery(document).ready(function($){ 2 $(document).on('click', '.prev-next-posts a', function(e){ 3 var $link = $(this); 4 var $container = $link.closest('.ife_archive'); // old container 5 var atts = $container.data('shortcode'); // shortcode attributes 6 var nextPage = parseInt($link.data('page')) || 1; 7 8 if (!atts || atts.ajaxpagi !== 'yes') return true; 9 10 e.preventDefault(); 11 $container.addClass('ife-loading'); 12 13 $.ajax({ 14 url: ife_ajax.ajaxurl, 15 type: 'POST', 16 dataType: 'json', 17 data: { 18 action: 'ife_load_paged_events', 19 atts: JSON.stringify(atts), 20 page: nextPage, 21 nonce: ife_ajax.nonce 22 }, 23 success: function(response){ 24 if(response.success){ 25 // Replace old container with new HTML 26 $container.replaceWith(response.data); 27 28 // Update $container reference for next click 29 var $newContainer = $('.ife_archive').filter(function(){ 30 return $(this).data('shortcode').ajaxpagi === 'yes'; 31 }).first(); 32 33 // Update pagination links dynamically 34 $newContainer.find('.ife-next-page').attr('data-page', nextPage + 1); 35 $newContainer.find('.ife-prev-page').attr('data-page', nextPage - 1); 36 } 37 }, 38 complete: function(){ 39 $container.removeClass('ife-loading'); 40 } 41 }); 42 43 }); 44});
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.