Back to contents

JetSmartFilters: How to Set Indexer Option for Filters

From this tutorial you will learn about indexing products or posts using JetSmartFilters functionality.

If you run an online shop or blog, where you would like to add filters to sort products or posts, you can use JetSmartFilters plugin. Let us introduce you new functionality, which is available in JetSmartFilters now and called Indexer.

What is Indexer? With this feature, you get the opportunity to save the filtering data in the database with its further retrievement. In other words, on the frontend will be displayed only the results relevant to the selected filter (the non-relevant results can be hidden or disabled).

We present an example based on filtering WooCommerce products using smart filters.

Setting Indexer option for filters

1 Step – Indexer setting overview

The first thing you should do is to go to the Elementor > JetSmartFilters Settings > Indexer block in the WP Dashboard. Here you need to move the toggle next to the Enable Indexed filters functionality option. Also, there is an index post types list, where you can specify the post types, which will be indexed.

enable Indexer

2 Step – Managing JetSmartFilters block in the WP Dashboard

Then, proceed to the JetSmartFilters block in WP Dashboard. Here you create needed filters. Also, you see the red Index Filters button, which you should click to apply Indexer functionality to smart filters every time when you customize the products or filters.

Smart filters

3 Step – Setting a filter widget

It is time to open the Shop page, where you have filters.
In JetSmartFilters widget’s settings you find the Indexer Options block, where you need to enable the Apply Indexer option. The Show Counter option allows showing the number of items of each product. Moreover, you can specify: to show, hide or disable an item in the filter if it is empty.

Indexer options

Select whether counters should be changed when filters are applied.

Indexer counter options
Indexer option is available only in Checkboxes Filter, Select Filter, Check Range Filter, Visual Filter, Radio Filter widgets.

4 Step – Viewing the result on the frontend

When you set all needed adjustments, click the Update button and view how an indexer option looks on the frontend.

Indexer in action on the frontend

Now you know how to show the number of items for each product using JetSmartFilter Indexer functionality.