WordPress.org

Support

Support » Plugins and Hacks » Display List of Author’s Comments? Not Posts

Display List of Author’s Comments? Not Posts

  • Greetings,

    I’m trying to figure out a way to list author’s comments in the author.php, similar to how one lists posts. Totally lost.

    (That is, I’m trying to allow my visitors on my site to be able to click on a name above a comment to be redirected to the appropriate author.php page, got that working, but now I just want to display the other comments by that author in that page).

    Been reading up about functions and stuff and searching through plug-ins but I can’t seem to find something to let me do this. I’m not really familiar with PHP though.

    I found this for an author’s posts, but can’t seem to find something like it for comments…:

    <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
            <li>
                <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link: <?php the_title(); ?>">
                <?php the_title(); ?></a>,
                <?php the_time('d M Y'); ?> in <?php the_category('&');?>
            </li>
    
        <?php endwhile; else: ?>
            <p><?php _e('No posts by this author.'); ?></p>
    
        <?php endif; ?>

    Thanks for your time!

Viewing 1 replies (of 1 total)
  • catharine
    Member

    @catharine

    Hey matsim — I’m trying to figure out how to do this, too, so I was disappointed to see that you didn’t get any responses…were you able to figure out how to do it? If so, I’d love to hear what you did.

    Thanks in advance!

Viewing 1 replies (of 1 total)
  • The topic ‘Display List of Author’s Comments? Not Posts’ is closed to new replies.