Customizing Filters, Search, and Sort

You can easily customize the filters, search, and sort options using a WordPress plugin called FacetWP. FacetWP offers a host of options that work seamlessly with the Elevent plugin.

2022-09-30 16_38_36-Event Grid - Standard _ Elefest QA.png

These filter, search, and sort pieces complement the Elevent Datepicker nicely--learn more about the datepicker here.

Before you add these facets, you'll first want to add an event display to your page--be that a grid, list, or something else. Filters and so forth don't really work without something to filter first.

What is FacetWP

FacetWP is a filtering plugin that provides you with a menu of types of filters, sorts, and searches that work in concert with some Elevent schedules and views.

During the installation, you should have already installed FacetWP, a set of FacetWP Pro add-on plugins, and imported a starting set of facets and listings.

You'll learn a little bit about FacetWP here, but for full documentation, visit the FacetWP Help Center.

Adding a filter/search/sort element to a page

The Elevent plugin starts you off with most of the filter, search, and sort options you'd want. That makes it easy to add them to any event grid or list.

You'll find these "facets" under Settings -> FacetWP

2022-09-30 16_40_35-FacetWP ‹ Elefest QA — WordPress.png

That's a lot to choose from. For our example, we'll add a genre facet to our page. This will show a dropdown field that allows the user to filter our events by genre.

Find the genre facet, hover over the cogwheel, and copy the shortcode.

genre-shortcode-copy.gif

Now visit your page. Add a shortcode to the page using whatever means you use to build pages in WordPress. Paste it your genre facet shortcode.

2022-09-30 16_46_11-Edit Page “Event Grid – Gutenberg” ‹ Elefest QA — WordPress.png



That's it--your genre dropdown filter is now in place. It will automatically show, as options, the genres of any ticektable events in the future. The events on display will filter to only those with that genre.

2022-09-30 16_46_56-Event Grid - Gutenberg _ Elefest QA.png

Note: the genre element will not display until you have events display of some sort. That could be an event grid, event list, or other from any supported method--such as a FacetWP listing, post grid, or any display option FacetWP works with.

Create Your Own Facet

You can go beyond the starting set of filter, search, and sort options. Again, FacetWP can do a lot; for the definitive list of facets available and all of the different ways you can modify them, see FacetWP's Help Center.

Let's create an A-Z Listing--this facet shows all the letters, like a little rolodex, and allows users to quickly filter by the starting letter of events.

alpha-filter.gif

Visit Settings -> FacetWP in the WordPress admin. Add a new facet.

2022-09-30 17_00_37-FacetWP ‹ Elefest QA — WordPress.png

Give it a name you'll remember, like "Alpha". Choose the type and what it will filter on--there are a lot of choices here, including all of the fields that come from Elevent. We'll be showing a grid or list of Elevent Events, which are custom post types in WordPress, so we'll just choose "Post Title".

newfacet.gif

Press Save Changes on the upper right. Then, Re-Index.

2022-09-30 17_05_15-FacetWP ‹ Elefest QA — WordPress.png

Lastly, let's add our new a-z listing to our page. Copy the shortcode as you did before, and paste that shortcode onto your page.

2022-09-30 17_06_47-Edit Page “Event Grid – Gutenberg” ‹ Elefest QA — WordPress.png

Alongside the genre filter we added earlier, we'll see an A-Z listing.

2022-09-30 17_07_22-Event Grid - Gutenberg _ Elefest QA.png

Not finding what you're looking for? Contact Us Directly