• like a lot of peoples’ blogs these days, my blog is about the comments as much as it is about the content. I’d like to create new ways for people to dip into the conversations that are breaking out across the site. .

    does anybody know of a plug in or hack that will let me display all comments on the site in a single ongoing thread? my guess is that hardcore users will love being able to browse comments as they come in.

    I’ve looked around for a plug in, so far no go

Viewing 7 replies - 1 through 7 (of 7 total)
  • Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    Well there’s the built in side-bar widget to list recent comments.

    You could also pull the widget code out and put it where ever.

    <?php
    $number=5; // number of recent comments desired
    $comments = $wpdb->get_results("SELECT * FROM $wpdb->comments WHERE comment_approved = '1' ORDER BY comment_date_gmt DESC LIMIT $number");
    ?>
    <ul id="recentcomments">
    <h2>Recent Comments</h2>
    <?php
    if ( $comments ) : foreach ( (array) $comments as $comment) :
    echo  '<li class="recentcomments">' . sprintf(__('%1$s on %2$s'), get_comment_author_link(), '<a href="'. get_comment_link($comment->comment_ID) . '">' . get_the_title($comment->comment_post_ID) . '</a>') . '</li>';
    endforeach; endif;?></ul>

    I don’t believe this will pull ’em from all blogs, though, if that’s what you’re after (you ARE posting in the MultiSite section, after all… We presume you’re using a network of sites)

    Thread Starter wordpig

    (@wordpig)

    thanks @ ipstenu

    yeah, I’m talking multisite – I’m ultimately interested in doing for both our blog and those we host, but that ambitiousness can come later.

    I”ll give your suggestion a shot

    actually, one more thing: I’d like to display the full text of each comment

    can you enlighten me as to how this could be done?

    or even if?

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    Probably by tossing in a get comment content call or something in this section.

    echo  '<li class="recentcomments">' . sprintf(__('%1$s on %2$s'), get_comment_author_link(), '<a href="'. get_comment_link($comment->comment_ID) . '">' . get_the_title($comment->comment_post_ID) . '</a>') . '</li>';

    You’ll have to search around in the functions.

    https://codex.www.ads-software.com/Function_Reference/get_comment is a start

    Thread Starter wordpig

    (@wordpig)

    @ ipstanenu

    thanks. that may be a little beyond my skills – which are pretty limited. but I’ll try playing around with it.

    @ andrea that sounds good. I may want to give that a try. maybe they’ll get around to fixing it

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    It’s probably more a function of the size of the SQL call. Recursively grabbing comments from a lot of blogs gets expensive :/

    maybe they’ll get around to fixing it

    It more depends on how they’re pulling the data really.

    there’s more but that;s the first free one I cam up with.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘commentology’ is closed to new replies.