james mckay dot net

because there are few things that are less logical than business logic
28
Dec

WordPress plugins update

I’ve been spending a while updating some of my WordPress plugins over the past day or so. It turns out that The Frame Buster had a bug that was stopping it working on some servers. If the version you are using is failing to override framesets as intended, or if you get an “undefined function does_host_match” error, you should upgrade to version 1.0.4. If you’re not sure, I’ve put up a page where you can test it here.

I’ve also released another plugin that I’ve been using for ages on end on my own blog, called Include. As its title suggests, it is similar to the <!--#include--> directive which is familiar to Apache or ASP/ASP.NET developers, in that it lets you include a file or PHP script in your blog posts.

26
Dec

Comment Timeout: Automatically closing blog comments on WordPress

Here is a WordPress plugin that automatically shuts off comments on older posts, unless they still have an active discussion going on.

Like everyone else, my blog was getting pretty heavily spammed. I have been using a combination of Akismet and Bad Behavior and this has had considerable success. However, I noticed that a lot of the spam comments that were coming through were targetting posts that were over a year old.

I’ve come across some popular blogs that are getting thousands of spam comments a day. Amazingly, nearly all of them keep comments open on all their entries, in some cases going back as much as four or five years. Why would anyone want to post a legitimate comment today on your trip to New York five years ago?

Since I started using this approach a couple of weeks ago, it’s proven to be pretty successful. Beforehand, Akismet was handling an average of five spams a day, with one day chalking up more than seventy. Bad Behavior knocked that figure down to typically one a day. Now, spam comments seem to be almost non-existent.

Some blog software such as CommunityServer and dasBlog has this functionality built in, though as far as I’m aware the ability to keep active discussions open is a new one. Unfortunately, WordPress has hitherto had no such facility, apart from a much simpler plugin which isn’t configurable and doesn’t allow for active, ongoing discussions.

This is a beta release of the plugin, and it has been tested on WordPress 2.0.5. Any feedback would be welcome.

[Update 28/12/2006]: I’ve created a separate page for the plugin, and released an update that is compatible with WordPress 2.1 alpha 3.