Searching in subcategories not working
-
Hi
First of all, greate Plugin, thank you very much!
I have exactly the same problem as described here.
After some tests if found out, that your resolving the subcategories in the function
relevanssi_search
with the wp functionget_term_children
.Your calling this function using the (auto-incremented) term taxonomy id instead of the “real” term id (id of the categories). In my case the category id is not the same as the term taxonomy id. So, the following line does not resolve the correct category..
$children = get_term_children($term_tax_id, 'category');
when I change this to the folling line, everything works just fine.
$children = get_term_children($t_cat, 'category');
I can see, that the second line returns the correct subcategories, while the original line of code doesn’t.
Thx for your reply.
Cheers Faebu
- The topic ‘Searching in subcategories not working’ is closed to new replies.