Configuring the Search Widget
GravityView's Search Widget (added in Version 1.6) allows you to search a View from anywhere on your site. Just add a widget to a sidebar and configure it!
Go to the Widgets page
Click on the widget labeled "GravityView Search"
Click the sidebar you want to add the widget to
Sites have sidebars that display in different places in the theme. Choose the sidebar you wish to add the search form to, then click the "Add Widget" button.
This is what the Widget looks like
- The widget title - this will be displayed above the search form
- The View selector - You will pick what View you want to search
- The Embedded Page ID - If you have a View embedded in post or page, you can define it here
Give the widget a title
This will be displayed as a heading above the search form.
Select a View
Select the View you want to search from the dropdown.
If you haven't configured any Views, you'll need to do that first.
If your View is embedded using a shortcode
If you want to have the search form search an embedded View, enter the ID of the post or page that you embedded the View on.
To find the ID of the post or page, look at the URL
While editing the post or page, look at the URL when you are editing a post or a page. Look for the numbers after ?post - that is the ID. In this example, URL reads
&action=edit, so the ID is 4751.
Enter the ID into the Page ID field
Enter the ID that you found in the previous step.
Configuring the Search Fields
Search fields will load once you select your View.
By default, there's one search field: "Search Everything". It does what it says.
Click the + button to add another search field
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.
Some fields will allow different input types
If you have multiple-choice field in your form, for example, you will be able to choose from different ways of displaying the search field.
Choose one value at a time from a drop-down list
Select (Multiple Values)
Allows easily selecting multiple values from a long list.
Allows one search value at a time
Allows searching multiple values in an easy-to-use checkbox format.
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.
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.
You can click the x icon to remove the field from the search configuration
Once you're done configuring, click the "Save" button
Our fully-configured Search widget
Check out your configured search form!
Go to your site and look in the sidebar - you'll see the GravityView Search Widget there.
Your search form will look different based on your theme. That's normal.