Is there a simpler way to do this? Using checkboxes in search query
I have a complex search function which considers input of the following types:
Right now I am having problems with checkboxes. The way I am doing it currently is:
- Create an event to display search results for the text the user inputs
- Create a condition for that event to occur only when the user has ticked a specific checkbox, e.g. "Active" (vs. Inactive). So this means only results with "Active" attribute will be shown.
These steps have to be repeated for every possible condition. i.e.
- User ticks active
- User ticks unactive
- User ticks both boxes
- User ticks no boxes
Then I have to also consider other search input... including other checkboxes for other attributes.
Is there a better way to do this? I am having trouble putting this together in the query builder since the results are dependant on which boxes the user ticks (if any), so I found using the conditions on the events worked best, but it is also tedious.