• I’m trying to display only 3 posts from a certain category (ID 9) and for some reason, it’s pulling the 3 most recent posts regardless of the category. Here’s the code I’m using… thanks for any help in advance.

    <?php query_posts('cat=9&showposts=3');?>
    <?php $posts = get_posts('numberposts=3&offset=0'); foreach ($posts as $post) : start_wp(); ?>
    <?php static $count1 = 0; if ($count1 == "3") { break; } else { ?>
    <div id="column_01">
    <h3><?php the_title(); ?></h3>
    <?php the_content(); ?>
    </div>
    <?php $count1++; } ?>
    <?php endforeach; ?>
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Help Displaying Only Category Posts’ is closed to new replies.