Add "the number of comments" next to the comment title

Community Forums Forums Design Tips and Tricks Add "the number of comments" next to the comment title

This topic is: not resolved

This topic contains 2 replies, has 2 voices, and was last updated by  Peter 2 years ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #1677

    Peter
    Participant
    Post count: 95

    By default, the comment title just says “Comments”.  How to show the number of comments?

    (e.g. “25 Comments” instead of just “Comments”)

    • This topic was modified 2 years ago by  Peter.
    • This topic was modified 2 years ago by  Peter.
    • This topic was modified 2 years ago by  Peter.
    • This topic was modified 2 years ago by  Peter.
    #1687

    Davinder Singh Kainth
    Participant
    Post count: 1453

    Following code should help:

    // B3- Modify comments header text in comments
    add_filter( 'genesis_title_comments', 'child_title_comments');
    function child_title_comments() {
    return __(comments_number( '{ No Comments }', '{ 1 Comment }', '{ % Comments }' ), 'genesis' );
    }

    Source – http://www.rickrduncan.com/add-comment-number-to-comment-title


    Need website customization services or other Genesis / WordPress help ?
    Davinder @ Design Studio iGuiding Media | My Blog | Fresh Genesis Themes Collection

    #1688

    Peter
    Participant
    Post count: 95

    Nice, that works.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.