Help get this topic noticed by sharing it on Twitter, Facebook, or email.

How do I add the word "comment"?

I have another question....how would I add the word "comments" to the information above each post. On the same line as the date.....thanks!
2 people have
this question
+1
Reply
  • EMPLOYEE
    I’m beer.
    1
    So, to add the word "comments" you'll need to edit both index.php and single.php. Look for the following line:

    <p class="date"><?php the_time('F jS, Y') ?> <?php comments_popup_link('§ <span class="commentcount">0</span>', '§ <span class="commentcount">1</span>', '§ <span class="commentcount">%</span>'); ?></p>

    This snippet displays three comment states - if there are no comments, if there is one comment, and if there is more than one comment. You are interested in the bits inside the parenthesis of comments_popup_link() - in case you want to change this again in the future. For now, just replace that bit of code with the following:

    <p class="date"><?php the_time('F jS, Y') ?> <?php comments_popup_link('§ <span class="commentcount">0 comments</span>', '§ <span class="commentcount">1 comment</span>', '§ <span class="commentcount">% comments</span>'); ?></p>

    That should do it!

    Andrea
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. kidding, amused, unsure, silly indifferent, undecided, unconcerned happy, confident, thankful, excited sad, anxious, confused, frustrated

  • This reply was removed.
    see the change log
  • This reply was removed.
    see the change log