• Resolved moutai

    (@moutai)


    Hello. On my website, I have products organized into categories such as “Product Type”, “Problem Type”, and “By Ingredients”. In addition, I’ve added a separate filter item“Brands”. Each of these categories also has its own subcategories.

    Currently, when I go to the main shop page (/shop/), the filter shows all available options, since this is the archive page. If I select, for example, a specific brand, the products are filtered correctly by that brand. However, the filter on the left still shows all filter options, even those that don’t apply to the filtered results.

    Is there a way to make the filter show only the options that have products available after filtering? The issue is that sometimes I select a combination that results in no products being found, and in that case, the entire filter disappears, since the archive page outputs .woocommerce-no-products-found.

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

    (@moutai)

    Or, is there an option to keep showing the filter on the left in combinations when there are no products in such a combination? For example, here’s how the page looks if there are products after filtering (screenshot 1), and here’s how it looks if there are none (screenshot 2). The client loses the ability to quickly re-filter and instead has to use the browser’s “back” button to go to the previous page.

    *realized that I can’t insert photos*

    • This reply was modified 8 months ago by moutai.
    Plugin Author annastaa

    (@annastaa)

    Hello Moutai,

    Unfortunately, the rules of this forum forbid me from discussing the Hidden Empty items style option available in the premium version. To give you another possible solution, let me draw your attention to the Add elements section of the annasta Filters > Product lists admin tab that provides the choice of adding a filters preset at the woocommerce_no_products_found hook. If your theme supports this hook, this will allow the insertion of your filters set into the “No products found” page, so you could easily try that to see if this resolves your issue.

    Thread Starter moutai

    (@moutai)

    Thank you so much. I will try this tomorrow and come back to you

    Plugin Author annastaa

    (@annastaa)

    Hello Moutai,

    It’s been some weeks since we’ve last heard from you, so I will close this inactive thread. You are welcome to open a new topic if you have any further questions about our filters!

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Hide empty filter options after filtering’ is closed to new replies.