Reefine
ExpressionEngine 2, ExpressionEngine 3, ExpressionEngine 4, ExpressionEngine 5, ExpressionEngine 6
Back to this add-on's main page
View Other Add-ons From Patrick Woodcock
Can you do conditional filters?
Support Request
jmg
|
Posted: 18 April 2017 09:32 AM |
|
|
|
I have a channel which includes two different fields for cities and states. Can I select the states with one filter and limit the cities with another?
|
|
|
Ralph
|
Posted: 18 April 2017 10:27 AM |
# 1
|
|
|
If I’m reading it right, you would like to hide the cities until the user selects a country? If you’re using method=“url” (the default) Then you could put a conditional in like this: (assuming the country is in segment 2 and the cities filter group is called cities_filter_group)
{if segment_2 != "" && segment_2 != "any"} {cities_filter_group} ... {/cities_filter_group} {/if}
|
|
|