Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter Antonio Augusto

    (@antonio24073)

    Hi,
    when clean a filter, my site crashes.
    See in: promophone.com.br
    Best Regards.

    Plugin Support Iván Sosa

    (@ivansosa)

    Hi there,

    We are testing the filter and also clearing the filters on your site, but we cannot replicate the problem.

    After clicking the clear filter button, the products and filters are restored as expected, but no sidebar dissapear.

    Could you share with us a screenshot with the problem replicated, please?

    Have a great day!

    Thread Starter Antonio Augusto

    (@antonio24073)

    Hi,
    I replaced the responsive sidebar with my own solution and the catch infinite scroll with yith infinite scroll and it worked now.
    Is there a way to do a javascript script like below?

    jQuery(document).on('yith-wcan-ajax-loading', function(){
        console.log('test');
    });

    and/or

    jQuery(document).on('yith-wcan-ajax-filtered', function(){
        console.log('test');
    });

    Best Regards

    Plugin Support Pablo Pérez

    (@pperez001)

    Hi there,

    Those 2 snippets are for different situation, the first one ( yith-wcan-ajax-loading ) is triggered before the filtering starts ( ajax call ). The second one ( yith-wcan-ajax-loading ) is right after the filtering has been completed.

    You can use any of them to add your custom js with the following code in the functions.php of your current theme:

    if( ! function_exists( 'yith_wcan_add_custom_js_code' ) ){
     function yith_wcan_add_custom_js_code(){
      $js ="jQuery(document).on('yith-wcan-ajax-filtered', function(){ /** or yith-wcan-ajax-loading**/
    
      /** Your js code here **/
    
      });";
      wp_add_inline_script( 'yith-wcan-shortcodes', $js );
     }
     add_action( 'wp_enqueue_scripts', 'yith_wcan_add_custom_js_code', 20 );
    }

    Let us know if it worked for you.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘When clear filters wp responsive sidebar disappear’ is closed to new replies.