Front page of muchad.com, show popular posts based on comments count. We can do it without plugin. To show some popular posts in WordPress we can do it with this simple script in your theme’s file.
This source code will show 3 popular posts. The problem, it only show posts with many comments count in all of time, so if no another post with comments count more than that posts, this post will be always shown like a static, no other post to show.
Trending Posts
To make it more flexible, muchad create a script that not only based on comments count but also “post like count” in a month, so it like trending posts in a month. Post like count is not default from WordPress, you must create it first. About creating “post like count” you can read this.
You can add this script to your theme to show trending posts in a month.
Try it, if you have any problem, just leave a comment. Like it? Please click <3