Problem with term_exists, it ignore parent = 0
-
Term_exists function returns the child category, although I’m only looking at the parents.
The structure of categories:
Category
– Titleistcode:
$ term = term_exists (‘Titleist’, $ taxonomy, 0);
echo print_r ($ term);answer:
Array
(
[term_id] => 1204
[term_taxonomy_id] => 1204
)Answer should be NULL!
Am I doing something wrong? How can I search only for the parent category?
Thank!
- The topic ‘Problem with term_exists, it ignore parent = 0’ is closed to new replies.