You can create a complete and nice Author’s page which will be displayed whenever someone clicks on an Author’s name link. The trick here is to create an author.php, this page will be displayed whenever you click on an author’s name link.
The Author page for an author can have all posts and comments by an author. To list all comments by an author you can use the code below.

comments, $wpdb->posts
    WHERE user_id = $curauth->ID
    AND comment_post_id = ID
    AND comment_approved = 1
    ORDER BY comment_ID DESC

 $comments_array = $wpdb->get_results($querystr, OBJECT);

if ($comments_array): ?>

Yumna Tatheer

I am a Computer Science graduate and a part time blogger from Lahore, Pakistan. I am a PHP programmer and a wordpress expert.

More Posts

Follow Me: