I have a multiple dropdown filters that lets users pick the category that they want to display results for below. See my previous question Search entries by location or name for screenshot.
So I have one working, but I need some guidance on how to do the code for the other filters as well, as currently my code for linking up to the second filter is stopping the first filter from working correctly. So clearly I'm doing it wrong.
So I have four dropdown filters, but I'll simplify it to two filters for this example. The filters are named name="county1"
and name="development1"
in their respective tags.
And then I'm using the following to access them:
{% set query = craft.request.getParam('county1') %}
{% set query = craft.request.getParam('development1') %}
{% set queryFilter = craft.categories.group('developments').search(query).order('title asc') %}
{% for category in queryFilter %}
....markup...
{% endfor %}
Can someone tell me what i need to do to fix this so that the filters don't interfere with each other?
{% set query = craft.request.getParam('development1') %}
and possibly that I need to set a second queryFilter row with different name? – mention79 Jan 16 '17 at 9:23