User Selections dynamically show each choice the user makes with the available facets on the page. The selections are grouped and displayed per facet and are preceded by the facet’s label.

The user selections can individually be clicked away, which dynamically resets that choice, and updates the results and facets. User selections are a good companion for a Reset facet, which resets all choices at once (or, depending on it’s settings, a selection of facets).

The code of the selections is a <ul>/<li> construction, with each facet’s choices grouped in a <li></li>, making them easy to style:

FacetWP User Selections
Default and custom styled User Selections

Note: The facet labels which appear before each user selection, are translatable with the facetwp_i18n hook.

Adding User Selections

Paste the following into an HTML widget, HTML block, or directly into your PHP template file:

echo facetwp_display( 'selections' )

Or use a shortcode:

[facetwp selections="true"]

Shortcode placement

Shortcodes can be added to the body field of your pages, or into Text widgets (Appearance > Widgets). If you’re using the WordPress 5+ block editor, you can paste shortcodes into a Shortcode block:

See also