Simon Willison’s Weblog

Subscribe

More thoughts on RSS

25th June 2003

I helped my girlfriend set up an RSS feed for her (home brewed) weblog last night. Explaining what RSS was was easy. Explaining what she needed to put in her feed took a little bit longer. All she needed to do was provide a feed of entries, each with a title, the full body of the entry, the date it was posted and a permalink to the archived entry. In working out how to do this, we identified the following steps:

  1. Pick an RSS version, out of RSS 0.9x, RSS 1.0 or RSS 2.0. The 0.9x series was out because there was no way of presenting the date of an entry, so it was between 1.0 and 2.0. 1.0 had all that unnecessary RDF stuff in (is there really a good reason for the <rdf:Seq> element?) so she went with RSS 2.0.
  2. Pick a date format, out of >dc:date< and <pubDate> (see Mark Pilgrim’s recent entry for information on the difference). <pubDate> won on the strength of being part of the core RSS 2.0 spec.
  3. Pick a way of serving the actual entries, from the following alternatives:
    1. Entity encoded HTML in the <description> element.
    2. Entity encoded HTML in a <content:encoded> element.
    3. Unencoded XHTML in a <body> element with a namespace.
    I advised her to go with the first option as I don’t know how good aggregator support for the other two is.
  4. Pick a way of providing the permalinks. Up until RSS 2.0 this would have been done with the nice and simple <link> element, but 2.0 introduced the more confusing <guid> element as well. The <link> element was chosen as the move obvious of the two.

It took less time to write the PHP than it did to decide on the elements to use in the feed in the first place. I’ve been following RSS for a while so I was in a position to guide her through the quagmire, but I can’t imagine it would have been much fun working it out without a guide.

I support the Road map for a new format. Another format may seem like the last thing we need but the current situation is pretty much untenable and forward motion has got to be a good thing. The few concerns I had have been answered by Tim Bray in his latest essay on the subject.

This is More thoughts on RSS by Simon Willison, posted on 25th June 2003.

Next: Moving forward from Internet Explorer

Previous: Tom Gilder's blog

Previously hosted at http://simon.incutio.com/archive/2003/06/25/moreOnRss