Title: &#8220;Top 10 Posts&#8221; Hack
Last modified: August 18, 2016

---

# “Top 10 Posts” Hack

 *  [Laughinglizard](https://wordpress.org/support/users/laughinglizard/)
 * (@laughinglizard)
 * [22 years, 5 months ago](https://wordpress.org/support/topic/top-10-posts-hack/)
 * I really liked the “Top 10 Posts” on [Jeremy Zawodny’s Blog](http://jeremy.zawodny.com/blog/)
   and wanted it for my blog as well. So I wrote a small hack which keeps track 
   of the number of times a particular post is clicked on (using the database) and
   then makes a list of these posts along with the number of clickthroughs. You 
   can see it in work on the sidebar ( [http://dinki.mine.nu/weblog/](http://dinki.mine.nu/weblog/)).
   Here is a [link to the hack instructions](http://dinki.mine.nu/word/b2-img/top10posts.txt).
   This is WordPress 0.72 and 1.0+ compatible.
    Also, to give my “Who is Online?”
   hack a little more exposure, here are the instructions to display the number 
   of users on your site at any time. [http://dinki.mine.nu/word/b2-img/whoisonline.txt](http://dinki.mine.nu/word/b2-img/whoisonline.txt)
   You can see it at work on my blog [http://dinki.mine.nu/weblog/](http://dinki.mine.nu/weblog/)(
   look at the “other” area)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [alexkingorg](https://wordpress.org/support/users/alexkingorg/)
 * (@alexkingorg)
 * [22 years, 5 months ago](https://wordpress.org/support/topic/top-10-posts-hack/#post-31020)
 * I thought about this a little while ago and I decided some kind of scale was 
   probably needed. This is what I came up with as an initial scale:
    1 point for
   a view on the home page 1 point for a view in the archives by date 2 points for
   a view in the archives by category 10 points for a view of the post by itself
   20 points for a comment 25 points for a trackback What do you think?
 *  [alexkingorg](https://wordpress.org/support/users/alexkingorg/)
 * (@alexkingorg)
 * [22 years, 5 months ago](https://wordpress.org/support/topic/top-10-posts-hack/#post-31026)
 * One idea I had was to just write everything to a text file and have a CRON job
   run every night (or 12 hours, etc) to do the database work.
 *  [stevecooley](https://wordpress.org/support/users/stevecooley/)
 * (@stevecooley)
 * [22 years, 5 months ago](https://wordpress.org/support/topic/top-10-posts-hack/#post-31032)
 * the initial part of this conversation works great. 🙂 Thank you! That was very
   easy to add.
 *  Anonymous
 * [22 years, 2 months ago](https://wordpress.org/support/topic/top-10-posts-hack/#post-31367)
 * blalblabla

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘“Top 10 Posts” Hack’ is closed to new replies.

 * 4 replies
 * 4 participants
 * Last reply from: Anonymous
 * Last activity: [22 years, 2 months ago](https://wordpress.org/support/topic/top-10-posts-hack/#post-31367)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
