/ Published in: PHP
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
function commentCountAuthor(){ $oneText = 'One comment'; $moreText = '% comments'; global $wpdb; $result = $wpdb->get_var(' SELECT COUNT(comment_ID) FROM '.$wpdb->comments.' WHERE comment_author_email = "'.get_comment_author_email().'"' ); if($result == 1): elseif($result > 1): endif; }
URL: http://wpcanyon.com/tipsandtricks/showing-amount-of-comments-a-comment-author-made/