how can i add a reset button at the end of all filter on shop page

[ad_1]

Hi @louisepanvig

To show the Reset button you can place the chips widget or shortcode [fe_chips] wherever you need and add the next example of CSS on the page with filtering. You can add it for example via Filters -> Settings -> Experimental -> Custom CSS

#wpc_chips_widget-2 .wpc-filter-chip:not(.wpc-chip-reset-all){
    display: none;
}

Where #wpc_chips_widget-2 is the chips widget wrapper and it may be different in your case. You can find it in HTML code. In general, this code hides all chips except the Reset button.

OPTION2 – code, that displays tag a with Reset URL

if( class_exists( 'FilterEverything\Filter\UrlManager' ) ){
    $urlManager = new \FilterEverything\Filter\UrlManager();
    $resetUrl = $urlManager->getResetUrl();

    echo '<a href="'.$resetUrl.'">Reset filters</a>';
}

So you can make out of this code your own shortcode with the needed template and styles.

Best Regards – Victor

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer