Problem: I have a custom field that holds a numeric value for length. I would like to create a front-end search filter for that length field with several options for a range of lengths, like "12 - 24", "24 - 35", "35 - 50", "50+".
Solution: There is no simple stepped-range filter like this in Types and Views. The simplest way to set this up in Toolset is to create a separate custom radio field with the options shown in your filter. You must manage the value of this field independently of the length field, so there will be some duplication of data, but the View filter will work correctly on the front-end of the site.
With a bit of custom code, you could automate this field value based on the length value. See another ticket with a similar request: https://toolset.com/fr/forums/topic/pricing-view-filter-in-parametric-search/
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
Sun | Mon | Tue | Wed | Thu | Fri | Sat |
---|---|---|---|---|---|---|
8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | - | - |
13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | - | - |
Supporter timezone: America/New_York (GMT-04:00)
This topic contains 2 replies, has 2 voices.
Last updated by 4 years, 9 months ago.
Assisted by: Christian Cox.