In the theme, you will have 3 options to set the Location option
- Google Places or OpenStreet Places AutoComplete
- Theme auto save location based on saved property location details
- With a dropdown selector
In this guide we will explain how to manage the listing location with dropdown selector
1. Adjust Search Location Autocomplete Settings
- Navigate to Admin > WpRentals Options.
- Go to Search > Location Field Search Settings
- Disable the option to Use Google Places or Open Street Places for Location Field in Search? (set NO)
- Locate Use Dropdowns for data saved from properties in Location Search Field?
- Choose between:
- No (Allows users to type in cities and areas as free fields).
- Yes (Displays pre-defined drop-down selection).
- Click Save Changes.
Using City and Area Dropdowns in Submission Form
- Navigate to Admin > WpRentals Options > Search > Location Field Search Settings
- Locate Use Dropdowns for Cities and Areas in Submission Form?
- Choose Yes (Displays pre-defined drop-down selections for cities and areas).
- Add Cities and Areas in Wp-admin -> Listings -> Cities and Areas. More here
- Go to User Dashboard > Add New Listing.
- Fill in the mandatory fields.
- Select the City from the dropdown.
- Select Area from the dropdown
- Select the Country from the drop-down list.
Note: Cities and Areas are independent
- Complete the location listing details – County And State
- Complete the remaining listing details and publish the listing.
Generating Data for Theme Autocomplete
- The City and Area are saved as listing property categories / taxonomies and as a autocomplete date.
- County, Country and State fields will save as autocomplete date
- The file with autocomplete data updates itself once a day (for performance)
- To instantly display new property details in the autocomplete location in form, manually generate the data from Map Configuration > Generate Data & Pins
- Click Save Changes. Refresh the page. Autocomplete file is generated
Searching for Listings Using Theme Autocomplete
- Go to the Homepage.
- Enter a location (e.g., London) in the Search Field.
- The manually added city and area will appear in the drop-down.
- Select the location and click Search.
- The matching listing will appear in the results.
Searching with Location Dropdown Enabled
- Enable Use Dropdowns for data saved from properties in Location Search Field?
- Select the property location in the search form from the dropdown
Configuring Search Form with the location field
The settings for theme autocomplete search will apply to all search forms that support location.
The following search forms are available in the WpRentals theme, and you may use them in any setup you wish with the Location Field search:
Hero Media Search (available in 5 variations). More here
- Type 1 – Default Search (hardcoded)
- Type 2 – Default Search (hardcoded)
- Type 3 – Supports Custom Fields only
- Type 4 – Default Fields (Hardcoded) + Custom Fields
- Type 5 – Supports Custom Fields only
Each of these variations may show as
- Mobile Search
- Search Shortcode
- Search Widget
Half Map Layout Search
- This form is configured exclusively with Custom Fields.
Search Form Builder in Elementor
- This form is configured exclusively with Custom Fields.
In these search forms, the location field can appear as:
- Default Field (“Where do you want to go?”)
Custom Field (“Location”)
Elementor Search Form Builder Field – Location
Searching for Listings Using Cities and Areas fields
In the search forms that support custom fields, you can set Listing City and Property Area (as separate and independent dropdowns):
- You can configure the names for these dropdowns in the Theme Options.
- Ensure you use the Compare Term “like” and set the Label that will display on the advanced search field on the frontend.
- You can set the dropdowns as classic dropdowns
- Or you can enable multi-select from Search > Categories Multi Selection