Bug with URLs when clearing filters
-
If you apply filter /category/categoryname/?filter_myfilter=filtername
and then hit “Clear filters” the URL will be /category/categoryname
without a trailing slash. It should follow the WP standard of appending trailing slash and follow the canonical URL, or you will have two cache versions of the same URL.
Hello,
Please find this file: woodmart/inc/integrations/woocommerce/template-tags.php then this function: function woodmart_clear_filters_btn() {
Then find this line:
$url = home_url( add_query_arg( array( $_GET ), $wp->request ) );
and replace it with this one:
$url = woodmart_shop_page_link();
Best Regards
You are welcome! If you have any questions please feel free to contact us.
Best Regards
The topic ‘Bug with URLs when clearing filters’ is closed to new replies.