Search form
[mapbox-search] shortcode has a bunch of own parameters. With this shortcode you can configure what to search and how to display on a separate search form. This separate search form can be connected with a map and/or listings by "uID" parameter in shortcode.
Complete list of [mapbox-search] shortcode parameters you can find here.
Search form is divided into 2 sections: "Main search block" and "Advanced search block" (hide/show by "More filters" and "Less filters" links).
Search settings allows to switch on/off particular search fields and functionality. Customization settings allows to configure background color, text color, background opacity and disable overlay (transparent waves) of the search form.
Main search block
This section includes 2 fields and radius slider:
- Keywords + Categories - possible to disable search by keywords and categories dropdown menu in the search settings. Also configure categories nesting level. This field has autocomplete functionality, it suggests listings and categories by first entered letters. When visitor enters keyword, the system searches through categories names and gives listings from corresponding categories, also it searches exact matches in listings titles, content and excerpt fields. Clear field to "reset" categories search.
- Address + Locations - possible to disable search by address and locations dropdown menu in the search settings. Also configure locations nesting level. This field has autocomplete functionality, it suggests locations by first entered letters and addresses or postal codes from MapBox service. When visitor enters keyword in this field, the system searches through locations names and gives listings from corresponding locations, also it searches exact matches in listings addresses (address line 1, address line 2, zip or postal code). Clear field to "reset" locations search.
- Radius slider - is used along with search by address. Visitors can find map markers in the radius of X miles/kilometers from entered address.
It is required for listings to have map markers on the map to be searchable by radius.
+ Search by content fields when they configured to take part in the search. Not all content fields have an ability to search listings by their values.
Advanced search block
This block is hidden by default and used only for search by content fields.
[mapbox-search] shortcode can open advanced search section by default by "advanced_open=1" parameter.
Connect Map and Search form
In order to connect search shortcode with map - enter uID parameter in the Map settings metabox.
Place both shortcodes in the page description. And the same parameter for the [mapbox-search] shortcode: