WordPress.org

Ready to get started?Download WordPress

Forums

Get Recent Comments
Feature Request: Separate trackbacks from comment count (1 post)

  1. gaplauche
    Member
    Posted 3 years ago #

    Hi,

    I love your plugin and use it on both of my sites/blogs. It works fine in WordPress 3.0 with the Thesis 1.7 theme.

    I'd like to make a feature request though. I recently used a custom php function to separate trackbacks from the comment counts on posts, but I notice it didn't have any effect on the comment counts for your plugin. I'm hoping you might modify the code below and include it in the next version of your plugin somehow. I'd like the number of comments displayed to match the actual number of comments that a post has.

    add_filter('get_comments_number', 'comment_count', 0);
    function comment_count( $count ) {
    if ( is_home() || is_single() || is_page() ) {
    global $id;
    $comments_by_type = &separate_comments(get_comments('status=approve&post_id=' . $id));
    return count($comments_by_type['comment']);
    } else {
    return $count;
    }
    }

    http://wordpress.org/extend/plugins/get-recent-comments/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic