Viewing 4 replies - 1 through 4 (of 4 total)
  • Moderator t-p

    (@t-p)

    what theme are you using?

    Thread Starter TinRoof

    (@tinroof)

    I’m using a theme that I bought. To be honest I don’t remember where I bought it. It was about a year ago or so.

    Hi,

    Add this code to your sidebar.php

    <?php
    $comments_count = wp_count_comments();
    echo $comments_count->approved;
    ?>

    Thread Starter TinRoof

    (@tinroof)

    Thank you for your help. I’m not sure where I put the code in. This is the code from my sidebar.php. Where do i enter this code?

    <div class=”left-sidebar”>

    <ul id=”sidebarleft”>

    <?php if ( function_exists(‘dynamic_sidebar’) && dynamic_sidebar(1) ) : else : ?>

    <?php endif; ?>

    </div>

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘How to add comment count?’ is closed to new replies.