I used Blosxom to build this site, partly because it’s fun to hack it, and it was a good excuse to learn Perl. My most notable contribution to the Blosxom community is a set of annotations to the Blosxom source code.

Recent entries for this category

Extensionless URIs for Blosxom entries

This post introduces the Blosxom plugin "extensionless". Ever since reading the essay "Cool URIs don't change" I've wanted to change my web site to conform to some of its recommendations, including the recommendation to omit file extensions (e.g., ".html") on URIs. Unfortunately standard Blosxom requires that a file extension be present in a URI for an individual entry (e.g., http://www.example.com/foo.html) to distinguish it from a URI for a category (e.g., http://www.example.com/foo). How to fix this? ...

The feedback plugin, an alternative to writeback

When I originally put up my blog one of the major things lacking was support for comments and TrackBacks. After looking at the various alternatives (the writeback plugin, the writebackplus plugin, and so on) I decided to embark on a complete rewrite of the writeback plugin in order to support my particular requirements for a comments system. After much struggle I created an initial version of my feedback plugin for publication and use on my site; since that time I've upgraded the plugin and incorporated bug fixes suggested by various people. ...

Patch for atomfeed plugin (UTC dates)

I recently experienced a strange problem with the Atom feed on my weblog. My weblog server is running on U.S. Eastern time as the basic time zone, but the story dates in the Atom feed should be expressed in UTC/GMT; the atomfeed plugin has code that supposedly should do any necessary conversions. On my local test blog (running under OS X 10.3 using Perl 5.8.1) this worked fine, but on my real blog (running on Red Hat Enterprise Linux 3 using Perl 5.8.0) the dates in the Atom feed were incorrect; they were five hours earlier than what they should be, suggesting that they didn't get converted to UTC/GMT. After some investigation this turned out to be due to non-portable code in the atomfeed plugin. ...

Patch seemore plugin for full text feeds

I use the seemore plugin by Todd Larason to show only excerpts of entries on my main blog page, index pages for categories, and archive pages, while displaying the entire article on an individual entry's page. It's worked well, with one exception: When I created my RSS and Atom feeds I wanted the feeds to contain the full text of all entries, for the convenience of people using news readers. (Many of these applications display article text directly in the reader, removing the need to open a browser window to read the article.)

To do this I made a minor patch to the seemore plugin, which I thought others might find of interest as well. The patch essentially bypasses seemore processing for selected Blosxom flavours (in my case, the 'rss' and 'atom' flavours).

Patch for entries_cache_meta plugin (meta values)

I've been using the entries_cache_meta plugin by Jason Thaxter, mainly for the convenience of specifying the modification date within the entry file. After a while I decided I'd like to also use its "meta" capability, i.e., the ability to specify arbitrary variables in the entry header along with the modification time, e.g.,

The entry title
meta-mtime: 2005/01/17 12:18:00
meta-foo: Whatever you want

The entry text begins here...

and then reference the variables as, e.g., $meta::foo within the story template (as is possible with Rael Dornfest's original meta plugin). Unfortunately, I couldn't get this to work at all. ...

Enforcing proper use of trailing slashes

I've previously blogged about my canonicaluri plugin that checks to see whether the requested URI is in the canonical form for the type of page being requested, and if necessary does a browser redirect to the canonical form of the URI. However the canonicaluri plugin may be overkill for some people, for example, it presumes use of the extensionless plugin, so that canonical URIs for individual entries do not have file extensions for the default flavour. A simpler alternative to the canonicaluri plugin is the slashredir plugin, which only enforces proper usage regarding trailing slashes. ...

Patch for atomfeed plugin ("modified" element for feed)

The "official" atomfeed plugin does not generate valid feeds for the current version (0.3) of the Atom specification because the output does not have a "modified" element for the feed as a whole, just "modified" elements for each story. Obviously the modification date/time for the feed can be interpreted as the date/time modified of the most recent story, so then it's just a matter of generating the proper output for the MODIFIED tags. ...

The lastmodified2 plugin

In a previous post I discussed the general problem of validating and caching dynamic content. In order to implement the strategy outlined in that post I decided to create a new version of the lastmodified plugin originally created by Bob Schumaker. The lastmodified plugin was a good base to build on; however it didn't do exactly what I wanted to do, and hence I couldn't resist trying to improve on it.

The following material documents the lastmodified2 plugin that I created, including my notes on how I implemented page validation according to my interpretation of the HTTP 1.1 specification. ...

Validating and caching dynamic content

One of the things I enjoy about setting up my own blog with the Blosxom software is learning about the deep details of web protocols and formats that I've never worried about before. (This might have been the case if I'd used another blogging system, but the hackable nature of Blosxom inspires, nay, almost demands it.) Lately I've been educating myself about HTTP conditional GET requests and validation and caching of dynamically-generated content.

In this post I discuss the subtleties of validating and caching dynamic content in general, and then in a separate post I tell how I created the lastmodified2 plugin for Blosxom, a rewrite of the lastmodified plugin. ...

Emptymessage patch for Apache compatibility, etc.

When stock Blosxom sees a URL that doesn't correspond to an existing entry or list of entries, it simply puts up a "normal" page (i.e., using the standard heat and foot templates for that flavour) that doesn't have any actual content. I really don't like this behavior, and thus I decided to try out the emptymessage plugin created by Fletcher Penney. Unfortunately I wasn't entirely happy with its behavior either, and so I decided to patch it. ...