• I got a code from

    <?php
    $cat = get_query_var('cat');
    $categories=get_categories('include='.$cat);
    if ($categories) {
      foreach($categories as $category) {
        echo 'Posts in this category = ' . $category->count;
      }
    }
    ?>

    My question is where to paste these code? Sorry I am a noob…

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘How to display the number of posts in category on category archive page?’ is closed to new replies.