Custom Parameters

Custom parameters lets you create custom lists for landing pages, modules, widgets and shortcodes.

Custom Parameters

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:

https://demo.jreviews.com/search/search-results?order=rating&dir=2&cat=23&query=all&usematch=1&filter=192&jr_state=new-york&jr_city=new-york

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 ?:

order=rating&dir=2&cat=23&query=all&usematch=1&filter=192&jr_state=new-york&jr_city=new-york

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:

order=rating&dir=2&cat=23&query=all&usematch=1&jr_state=new-york&jr_city=new-york

Since we only want the top 10 results, set both Page Total and Page Limit to 10 in the menu settings.

When you perform a proximity search for restaurants in Boston you get a search query that looks like this:

order=distance&dir=2&cat=24&query=all&jr_radius=5&jr_latitude=42.3584308&jr_longitude=-71.0597732

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:

Period Value
Last 7 days -7
Last 30 days -30
Today today
Today and after future
This Week week
This Month month
Next 7 days +7
Next 30 days +30
After a specific date higher_date_YYYY-MM-DD

Below you can find a few examples to get you started:

All events this week

jr_eventdate=week

Events this month

jr_eventdate=month

Events in the next 7 days

jr_eventdate=+7

Events after in 2020

jr_eventdate=higher_date_2020-01-01

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

jr_eventdate=week&jr_radius=5&jr_latitude=42.3584308&jr_longitude=-71.0597732

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:

http://demo.jreviews.com/search/search-results?cat=23&rating[]=4,4&rating[]=4,6

The resulting value for Custom Parameters setting then becomes:

cat=23&rating[]=4,4&rating[]=4,6

The equivalent for editor ratings is:

cat=23&editor_rating[]=4,4&editor_rating[]=4,6

The notation for the rating criteria filtering requires 2 values, the rating and the rating criteria ID:

rating[]=RATING_VALUE,RATING_CRITERIA_ID

  1. RATING_VALUE is the overall rating for the rating criteria and will look for results equal or greater than the specified value.
  2. RATING_CRITERIA_ID is rating criteria ID which can be found in the Listing Type.