Related Posts – Exclude categories by parent category
-
I have managed to exclude muliple categories by following the details on this post, but what I actually want to achieve is to exclude a particular category AND it’s children/grandchildren, so I don’t have to keep going back when new children/grandchildren are added.
I’ve tried variations on
$filters[] = get_categories( array( 'child_of' => 'slug' ) );
but I think the problem sits with slugs vs category ID’sAny help appreciated.
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Related Posts – Exclude categories by parent category’ is closed to new replies.