Added hit counter to blog posts

Hit counters are cool so I've added one at the end of my blog posts. Wish I did this a long time ago as it does not show historic data (would have over 100k on some!!)

It works by just incrementing a number in a database if your user agent does not contain "bot" or "crawler". So it's ripe for abuse ;)

This does go against the philosophy of adding new features to my website that I detailed in this post but it's cool.

It did also reinforce my idea though. I completely messed up database migrations (different between dev/prod) and took awhile to fix. Don't want to have to deal with that on a personal site.


63 views

Published on Feb. 13, 2025, 6:53 p.m.

Reply by email


tags: microlog