1jQuery(document).ready(function($){ 2 3 function initMasonry() { 4 var $grid = $('.event-post-grid'); 5 if ($grid.data('masonry')) { 6 $grid.masonry('destroy'); 7 } 8 9 $grid.imagesLoaded(function(){ 10 $grid.masonry({ 11 itemSelector: '.event-item-wrapper', 12 percentPosition: true, 13 gutter: 0 14 }); 15 }); 16 } 17 18 function fetch_events() { 19 var status = $('#event-status').val(); 20 var event_type = $('#event-type').val(); 21 22 $.ajax({ 23 url: events_ajax.url, 24 type: 'POST', 25 data: { 26 action: 'filter_events', 27 status: status, 28 event_type: event_type 29 }, 30 beforeSend: function() { 31 $('#events-results').html('<div class="ajax-loader"><div class="loader"></div></div>'); 32 }, 33 success: function(response) { 34 $('#events-results').html(response); 35 initMasonry(); 36 } 37 }); 38 } 39 40 initMasonry(); 41 42 $('#event-status, #event-type').on('change', fetch_events); 43});
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.