1/** 2 * УнивеÑÑалÑÐ½Ð°Ñ Ð¿Ð°Ð³Ð¸Ð½Ð°ÑиÑ. Ð Ñаблоне, в коÑоÑом добавлÑеÑÑÑ Ð¿Ð°Ð³Ð¸Ð½Ð°ÑÐ¸Ñ - нÑжно добавиÑÑ ÐºÐ»Ð°ÑÑÑ Ð±Ð»Ð¾ÐºÐ°Ð¼: 3 * .js-items-container - РблокÑ, где Ð½Ð°Ñ Ð¾Ð´ÑÑÑÑ ÑлеменÑÑ 4 * .js-item-container - Ð Ð±Ð»Ð¾ÐºÑ Ñамого ÑлеменÑа 5 */ 6$(function(){ 7 $(document).on('click', '.js-btn-more', function(){ 8 9 let items_container = '.js-items-container'; 10 let item_container = '.js-item-container'; 11 let url = $(this).data('next_page'); 12 let btn_container = $(this).parent(); 13 14 if(url){ 15 $.ajax({ 16 type: 'GET', 17 url: url, 18 dataType: 'html', 19 success: function (data) { 20 21 let items = $(data).find(items_container).find(item_container); 22 let btn = $(data).find('.js-btn-more'); 23 24 $('.js-btn-more').remove(); 25 26 $(items_container).append(items); 27 btn_container.append(btn); 28 } 29 }) 30 } 31 }); 32});
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.