Hi again,
we’ve just made some tests in our local installation and we see the “infinite scrolling” needs to be re-loaded after filtering products with WooCommerce Product Filter by WooBeWoo.
Please try adding the following code snippet to your theme functions.php
if ( ! function_exists( 'yith_infs_customization_woobewoo_product_filters_fix' ) ) {
add_filter( 'wp_enqueue_scripts', 'yith_infs_customization_woobewoo_product_filters_fix', 999 );
function yith_infs_customization_woobewoo_product_filters_fix() {
$js = "jQuery(document).ready(function ($) {
if( typeof yith_infs === 'undefined' ) {
return;
}
var infinite_scroll = {
'nextSelector' : yith_infs.nextSelector,
'navSelector' : yith_infs.navSelector,
'itemSelector' : yith_infs.itemSelector,
'contentSelector' : yith_infs.contentSelector,
'loader' : '<img src=\"' + yith_infs.loader + '\">',
'is_shop' : yith_infs.shop
};
document.addEventListener( 'wpfAjaxSuccess', function(){
$( window ).unbind( 'yith_infs_start' );
$( yith_infs.contentSelector ).yit_infinitescroll( infinite_scroll );
});
});";
wp_add_inline_script( 'yith-infs', $js);
}
}
and let us know if everything works fine!
-
This reply was modified 4 years, 5 months ago by YITHEMES.