I’ve been trying to display posts from a single category in a parent category template, but for some reason, the child posts I’m trying to exclude aren’t being excluded. My category template is called category-work (the name of the parent category, id 1) and I want to only display posts from the child category 4, but exclude posts from child categories 5, 6 and 7. So, posts in categories 5 and 6 don’t display, but the post in category 7 does. I can’t imagine what could be going wrong…
This is my code.
- The topic ‘excluding posts in a category with query_posts’ is closed to new replies.