Custom parameters lets you create custom lists for landing pages, modules, widgets and shortcodes.
Creating landing pages with custom parameters is just a matter of getting the results you want on your site via search or filtering. Then copying the search parameters from the URL into the
Custom Parameters setting in the
Custom Lists menu.
Yes. It's really that easy 🤯
Custom parameters can also be used in listings shortcodes, modules and widgets.
Using the demo site for the first example "Top 10 Restaurants in New York", we use the advanced filter module in hotels to search for listings in New York, New York. And then sort the listings by highest user rating.
The resulting URL is:
Simplifying Custom Parameters
To use the search URL above in
Custom Parameters in the
Custom List menu, we only need the
query part of the URL, which is everything that comes after the
Even this can be further simplified by removing the
filter parameter which is not needed to retrieve the correct results. So we end up with:
Since we only want the top 10 results, set both
Page Total and
Page Limit to 10 in the menu settings.
Parameters with Proximity Search
When you perform a proximity search for restaurants in Boston you get a search query that looks like this:
The address field can be excluded because only the coordinates are needed for proximity searches. You can also adjust the radius and order parameters.
Parameters with Dates
When it comes to dates and custom parameters, you can also create dynamic pages that retrieve results based on a relative time period, rather than using fixed dates.
The following values are valid for use with date custom fields:
|Last 7 days
|Last 30 days
|Today and after
|Next 7 days
|Next 30 days
|After a specific date
Below you can find a few examples to get you started:
All events this week
Events this month
Events in the next 7 days
Events after in 2020
Of course you are not limited to just using a date field for filtering. This can be combined with other search criteria as well.
Events this week in Boston
Parameters with Rating Criteria
It's also possible to add rating criteria filtering to custom parameters. For example, to list Hotels in New York with an average user rating of 4 and higher, for both Location and Pricing criteria the URL would look like this:
The resulting value for
Custom Parameters setting then becomes:
The equivalent for editor ratings is:
The notation for the rating criteria filtering requires 2 values, the rating and the rating criteria ID:
RATING_VALUE is the overall rating for the rating criteria and will look for results equal or greater than the specified value.
RATING_CRITERIA_ID is rating criteria ID which can be found in the Listing Type.