Display the Total Comments Count in WordPress
If you have a good number of comments on your WordPress blog, and want to show your users the same, you can do this by simply following the tutorial above.
If you have huge number of comments on your blog you can display total number of comments on your WordPress blog's footer or sidebar.
This can encourage users to read other posts also and may increase your pageviews.
If you have huge number of comments on your blog you can display total number of comments on your WordPress blog's footer or sidebar.
This can encourage users to read other posts also and may increase your pageviews.
Displaying Total Number of Comments in WordPress Sidebar
It's very simple just open your sidebar.php file, and paste the following code where you want to show off comments count:
If you want to add it in footer just instead of editing
Feel free to ask for any help regarding this tutorial in comments.
<?php $comment_count = wp_count_comments(); echo $comment_count->approved . " Comments, Your custom message here"; ?>you can change "your custom message here" to anything you want to add or delete it.
If you want to add it in footer just instead of editing
sidebar.php
edit the footer.php
file.Feel free to ask for any help regarding this tutorial in comments.
Comments
Post a Comment