exclude cat redux
-
I’ve got a page on one of my sites that should only show certain posts from certain categories. I’ve gotten as far as creating my loop but I think I’m doing something wrong. With this loop it shows only children of cat 5 but it’s not excluding cat 13. It is excluding cat 16. Anyone able to tell me what I’m doing wrong? Thanks in advance! Code to follow.
-A
<?php $cats = get_categories('orderby=id&order=DESC&child_of=5&$category->cat_ID>16&exclude=13&exclude=16'); // This is a loop that pulls any special categories foreach ($cats as $cat) : echo '<h1>' . $cat->name . '</h1>'; query_posts( 'orderby=date&order=ASC&cat='.$cat->term_id ); if (have_posts()) : while (have_posts()) : the_post(); ?> <?php the_content(); ?> <?php endwhile; endif; wp_reset_query(); ?> <?php endforeach; ?>
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘exclude cat redux’ is closed to new replies.