Configuring the Search Bar

GravityView's Search Bar allows for some great configuration options.

Click "Add Widget" button

If you're creating a new View, you will need to Start Fresh or choose a Data Source before you can see the Add Widget button.

Add widget button highlighted for widget configuration above entries

Click the Search Bar widget

Widget menu highlighting the option to add a search bar for searching entries

Click the Settings gear to configure the search

Click gear icon next to Search Bar to configure settings

This is what the search bar settings look like

The Search Layout setting toggles between showing fields side-by-side ("Horizontal") or stacked on top of one another ("Vertical")

The "Show Clear button" adds an option to reset the search results. Read more about the Clear button here.

By default, there's one search field: "Search Everything". It does what it says.

Search bar settings with layout options, clear button toggle, search field, label, and input type configuration

Click the + button to add another search field

Add a search field by selecting "Search Everything" and clicking the green plus button

Then click the drop-down that was just added under Search Field

You can select from any search field in your current form. Here, we are adding a search field for the "Job Title" field. This will search just the Job Title for entries.

Dropdown displaying search field options like Job Title in a configuration interface

A new "Search Mode" setting will appear

When you have multiple search fields, you'll be presented with a Search Mode setting: do you want all the search fields to be matched for an entry to be displayed, or do you want to show an entry if any of the fields are matched?

Search bar settings, selecting between "Match Any Fields" or "Match All Fields" for search results

You can change the label of a search field by modifying the "Label" value

If left blank, the default value will be used. The default values are shown in light grey.

If you don't want to display a label for the search field, insert a blank space.

Some fields will allow different input types

If you have a multiple-choice field in your form, for example, you can choose from different ways of displaying the search field.

Dropdown menu for configuring search input types, showing options like select, radio, checkbox, and links

Select

Choose one value at a time from a drop-down list

Dropdown menu labeled "Employment Type" for selecting job categories

Select (Multiple Values)

Allows easily selecting multiple values from a long list.

Dropdown menu with employment type options; full-time, part-time, contractor

Radio

Allows one search value at a time

Radio button options for job types: Full Time, Part Time, Contractor, Intern, Seasonal

Checkboxes

Allows searching multiple values in an easy-to-use checkbox format.

Checkbox options for job types: Full Time, Part Time, Contractor, Intern, Seasonal; Full Time, Contractor checked

Links

The Links search type displays a list of links to filter by a specific value. When the filter is clicked, the active filter is bolded.

Filter options for job types: Full Time, Part Time, Contractor, Intern, Seasonal

Once you have added fields, you can drag and drop them to reorder.

Click and drag on the arrows to the left of the Search Field dropdowns. Drag up or down to re-order the fields.

Search bar configuration interface with fields for search, date, and employment types. Options to add or remove fields

You can click the x icon to remove the field from the search configuration

Click the red 'X' icon to remove a search field configuration option

Once you're done configuring, click the "Close" button

Search bar settings: Select "Match Any Fields" or "Match All Fields". Click "Close" to finish configuration

Then Save or Update your View

Embed shortcode section with update button highlighted for saving changes

Check out your new configured search form!

Image from Article: Configuring the Search Bar
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us