The Internet Never Forgets

September 01, 2011

When I switched from WordPress to Octopress I heavily edited my .htaccess file on the assumption that no one would still have a bookmark to one of my old posts using an out-dated URL. That assumption was wrong.

In October 2003, for example, I posted a comment on a piece about the contents of your dock. And wouldn't you know, that posting still gets traffic eight years later and that traffic still follows links buried in the comments, one of which leads to my site.

I know all of this thanks to Mint and the Error Tracker Pepper.

So this morning I reassembled my .htaccess file, bringing back in all the old MoveableType redirects, and while I was at it, I added one to catch all the old monthly archive pages too. The MoveableType redirects are specific to my site, but the basic format looks like this

Redirect 301 /blogs/######.html

I no longer have the script I used to generate these, but it read the meta data for each posting exported from MoveableType in order to match up the meaningless 6-digit posting number with the Year, Month, Day, and post title for each entry.

The monthly archive redirects were easier to deal with as that URL pattern could be neatly fit into a regular expression:

Redirect 301 /blogs/\d{4}_\d{2}.html

In order to really clean things up I need to create a categories page that shows my remaining categories, with links to pages showing the entries for each of those categories, and once that hierarchy is in place, redirect old category links to that page. That will have to wait for another day. Until then the 404 page will have to suffice.

Author's profile picture

Mark H. Nichols

I am a husband, cellist, code prole, nerd, technologist, and all around good guy living and working in fly-over country. You should follow me on Twitter.