I've searched but can't seem to find a definitive answer. Can I exclude multiple categories using query_post?
<?php
if (is_home()) {
$paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
query_posts("cat=-26&cat=-36&paged=$paged");
}
?>
I read at another website that if I put the excluded categories into a parent category, I can exclude the parent and the children with one variable, but I would prefer not to do that.
User:JamesVL/query_posts
Looks like the issue maybe that if the post in question is included within another category, the post will be included.
drmike - I've looked at the link and that addresses only the exclusion of one category.
I know that I could do it conversely - i.e., list all the categories to be <i>included</i> but it's easier to exclude 2 categories than include 20.
Are you saying, though,a s long as the post is marked with just one category, that the multiple category exclusion should work?