Patching Bot Check plugin for WP 2.0

Having upgraded to WordPress 2.0 the other day, I knew that something had gone horribly wrong with the Bot Check plugin when I logged into my dashboard today and saw 33 comments in the moderation queue. A quick test revealed of course that Bot Check was accepting comments without the numeric code.

I found the solution in comment 87 on the Bot Check page.

This plugin doesn’t work because “post_comment_text”, the filter it hooks into WordPress with, was deprecated but still supported in WP 1.5. It has totally gone away in WP 2.0.

If you change “post_comment_text” to “preprocess_comment” in bot-check.php, everything works the same way as it always did. (Including eating the comment text if the user enters the wrong numeric string.)

Unfortunately, as is typical with WordPress plugins, the author has not released a new version. I had to make the change myself.

Anyway thankfully now it’s working. Thanks, number 87!

Oh and a big middle finger to the asshole(s) who were attempting to cover my blog with porn links. Now I can go back and pretend that you don’t exist once again.


3 thoughts on “Patching Bot Check plugin for WP 2.0

  1. I seem to be struggling with getting this program working properly myself. I made the same change you alluded to above, but it just won’t work for me. I keep wondering if a change to another file was also needed; oh well,…

Leave a Reply

Your email address will not be published.