BLOGARHYTHMS> 'S PICK OF THE DAY'S BEST BLOGS

How I built an effective comment spam blockerSnook-45X64.jpg
Posted by Jonathan Snook

Mention comment spam and most people, in particular those crazy WordPress users, mention Akismet. Great tool and I have nothing against it but I wanted to build my own, avoiding the external call to the Akismet service. What has been interesting to see, is just how effective it is. Turns out, my spammers are quite obvious. As you might see, I don't use CAPTCHAs and I don't use JavaScript detection. I just use a number of rules that validate each comment on the server. Oh, and I don't use nofollow. Points System I use a points system, which I got the idea from Movable Type, whose spam protection is also based on a points system. For everything in a comment that I like, you get a point. For everything I don't like, you lose a point (or two, or three). If you get a 1 or higher, you've made it on the site as a valid comment. If you get a 0, it's set for moderation and I'll take a look at it. If it's below 0, it's marked as spam and I'll never see it (although I check every couple weeks just in case a legitimate comment needs to be unflagged). If it falls below -10, I don't even bother saving it to the database since it is so obviously spam. Click here to read more of Jonathan's blog.

Submit a comment

Please leave your name, which will be used to sign your submission to the SCANsite. Thanks for contributing your thoughts. Come back again. Tony Patterson, Editor & CEO.

© 2006 - 2009 SCAN
INTEGRITY INTELLIGENCE INFORMATION
Site by Citadel Rock
SCAN