A lot of blogs are displaying social media followers and network links as a count on the main page. It serves as a good measure of how popular the blog or website has become.
But a lot of blogs forget the internal community or reader comments. A popular blog always has a lot of comments under each post as readers discuss points of view and information with the author.
So instead of displaying the total number of social media followers and social network links it might be a great idea to display the total number of comments that exist on the blog or site in question.
Display Number of Blog Comments
Before continuing, the next step requires proper FTP access to the related blog or website so this feature can only be implemented by the blog owner or a site admin.
The following code can be implemented by using the integrated WordPress theme and HTML editor but IS NOT compatible with the widgets feature.
Place the following segment of code where you would like the comment counter to appear:
<?php $numcomms = $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->comments WHERE comment_approved = '1'"); if (0 < $numcomms) $numcomms = number_format($numcomms); echo "".$numcomms." total blog comments"; ?>
Of course this code can be customized and spruced up to be a little more visual, but ultimately it will just output a text based counter of the total blog comments.
A more direct example of the code in action can be seen below.
All finished! You should now be rewarded with an accurate ticker of total blog comments.