Avada pagination possible issue
Sometimes using HUSKY Filter with the Avada theme, filters are lost when navigating to page 2 or any subsequent pagination pages. The filtering works correctly on page 1, but breaks completely when clicking pagination links like /page/2/.
Symptoms:
- Filters work on page 1:
https://example.com/shop/fltr/product_cat-category/✅ - Filters lost on page 2:
https://example.com/shop/fltr/product_cat-category/page/2/❌ - All products are shown instead of filtered results
Root Cause
The issue is caused by Avada’s shop_template_loader() method in the Avada_Woocommerce class, which modifies the WordPress query object when custom shop page templates are used.
Problematic code location: /wp-content/themes/Avada/includes/class-avada-woocommerce.php
To resolve this issue, add the following code to your current WordPress theme’s functions.php file:
add_action('template_redirect', function() {
global $wp_query;
// If WOOF is filtering
if (is_woof_search_going()) {
$wp_query->is_search = true;
}
}, 1); // Priority 1 - VERY early, before everything
Troubles? Ask for Support!
