Documentation / Filters & Filter Sets / Filter

Filter

Overview

The Filter is mainly the parameter by which posts are filtered. For example, it can be a product category, price, product attribute, or any other criterion by which you can combine posts. But in addition, the filter also contains a number of other parameters that determine its properties such as behavior, look, filtering logic and other.

Filters can be Taxonomies, Custom Fields and Author, so you can filter WooCommerce products or WordPress posts by almost any parameter!

Technically Filters as Filter Sets are also a separate Post type in WordPress, so this allows you to create unlimited numbers of them. The filter can only exist within the Filter Set.

Basic Filter fields

Name Description
Title The name of the Filter. It is displayed in the filter widget. Optional.
Filter by Criterion by which posts will be filtered. It can be anything related to Taxonomy, Custom Field or Author in WordPress. Required.
Meta Key Name of the Custom field by which posts will be filtered if you select one of the Custom Field filtering options.
Prefix for URL Determines which word or symbols will be contained in the part of the URL that correspondents to this Filter. It’s something like WordPress slug. Supports alphabetic symbols, hyphens, underscores and numbers. Required.
View in Widget Specifies the view of filter in the Filters widget. Possible values are:
– Checkboxes
– Radio Buttons
– Labesl list
– Dropdown
– Range

Prefix for URL

For example, Prefix for URL value is “color”. It means that the URL of the filter results page will contain a section /color-blue-or-yellow/ or &color=blue;yellow if you do not use permalinks in WordPress.

Once specified Prefix for URL value can not be changed for the Filter. You can only edit it globally.

Filter by, Prefix for URL and Meta Key

You cannot change the values of the Filter by, Prefix for URL and Meta Key parameters for an existing filter. However, you can always remove this filter and replace it with a new one.

All filters with the same “Filter by” value must have the same values “Prefix for URL”. You cannot change them separately for each such Filter, but you can change them globally on the
Filter > Settings > URL Prefixes screen.

Additional Filter fields

Additional Filter fields can be seen by clicking “More options”. They allow you to configure settings that do not change as often as the basic settings and are therefore hidden by default.

Name Description
Filter Logic Filtering logic. Possible values are “OR”, “AND”.
– “OR” means to show posts that are present in at least one of the selected terms.
– “AND” means to display only those posts that are present in all selected terms at the same time.
Sort Terms by Determines criteria by what to sort terms in the Filters widget and the order of this sorting – descending or ascending.
Exclude Terms Allows to specify which terms should be excluded from the Filters widget.
Folding Determines whether to collapse or not a Filter in the widget. If enabled, then the filter terms will be hidden in the widget until user clicks the Filter opening icon.
Show Selected Determines whether to display the selected terms in the general list of selected terms. Enabled by default.
Use for Variations Determines how to filter variable products – by the properties of their variations or their parent products.
Show Hierarchy Determines whether to show the hierarchy of terms in the Filter. If enabled, child terms will be hidden in collapsible list by default. Disabled by default.
Search field Adds a search field above terms list in the Filters Widget and provides quick search among them.
Enable Range Slider? Determines whether to display the Range slider for the “Range” view in Filters widget.
Slider Step Determines the step with what to change Range slider value. Can be a number, optionally with a fractional part. Default value is 1.
Tooltip Short explanation for a Filter which appears in the Filter title. Useful for situations, when filtering criteria is not obvious and requires additional explanation

Managing Filters

Create a Filter

On the edit screen for a new or existing Filter Set click the Add Filter button and you will see an expanded form with Filter settings. Edit the Filter fields and click the the Publish/Update button to save all Filters and their settings.

Remove a Filter

The removing Filter button is hidden by default for security reasons. To see it and use it you need to open the desired Filter and click on the link Delete at the bottom left in the Filter editing form. After this at the bottom right you will see a button Delete, I’m sure – click it and confirm the deletion. The filter will be removed immediately, no need to update the Filter Set.

Filters Order

You can change filters order in the Filter widget by dragging filters to top or bottom.
Move cursor above Filter’s number on the left, grab it and move to desired position.
Don’t forget to Update Filter Set settings.

Inactive, grey Filters

If the Filter in Filters list is grey it means that it doesn’t match selected Post type so you can not filter posts by its parameter. You can to change Post type to correct value or delete the Filter.

Make your filtering best with