How to show the total number of comments in WordPress

Adding below code snippet to your WordPress theme will display the total number of approved comments.

 
<?php
 
	$number_of_comments  = get_comment_count();  
	$number_of_commentsm  = $number_of_comments['approved']; //approved, 
 
	echo $number_of_comments;
 
?>

Related posts:

HTML5 page structure

HTML5 offers more powerful structure comparing to older versions of Html. There are many new …


Partner with Us

We are providing an exclusive partnership offer to individuals and companies who are interested in setting up their own web design & development company. For more information about how to partner with us, please contact us