Forums › Forums › Search & Filter Pro › Combine two categories: it doesn’t work
- This topic has 3 replies, 2 voices, and was last updated 4 years ago by
Trevor.
-
Anonymous(Private) February 2, 2021 at 11:10 am #274960
Hello everyone,
I have a little problem.
Let’s say i have two categories in WordPress with children:– Budget
– – Between 50€ and 100€
– – Between 100€ and 200€
– Location
– – Europe
– – AmericaI want to filter the budget with a dropdown and the location with checkboxes.
How i can do that with S&F Pro?I used two categories in my form:
For each category, i excluded the ID’s of the other category.
So it works, i have the budget in a dropdown and the location with checkboxes but… It’s not possible to use the operator “AND” for the 2 categories. I cannot choose for example a place in Europe between 50€ and 100€.
My URL is limited to 1 choice:
https://www.mydomainname.com/?_sft_category=europe%20america
But i need:
https://www.mydomainname.com/?_sft_category=europe%20between50and100
Thanks for your help!
Sébastien
Trevor(Private) February 2, 2021 at 11:41 am #274970You are using ‘Category’ twice times in the form, which is not allowed (as you have discovered).
You need to separate out groups of terms into separate custom taxonomies. In general, you can use a particular Taxonomy, such as Tags, (or Category, each Custom Taxonomy and each Custom Field) only once in the form. This post tries to explain this a bit better (you can use a plugin to switch category terms from category to any new taxonomy that you make, so it is not so hard to do). It is a really awful preachy lecture I wrote:
https://support.searchandfilter.com/forums/topic/multiple-categories-combination/#post-55166
Sorry about the tone, but the message is right and it links to good plugins (except taxonomy switcher I think). It is most important that you change any child terms into parents before moving them (you will not need the parent terms, as they become their own taxonomy).
-
AuthorPosts