Writing An RSS Feed
Friday 9th September 2005
Categories: Guides, Internet, Code
Choosing The Feed Version
So now we come to that important decision, which feed do we actually use? First of all, I'm going to exclude Atom. Although it is relatively well known, RSS is still more likely to be supported than Atom. If Atom were to be better supported, I would probably go for Atom. Unlike Atom, RSS is not controlled by a standards body or consortium, meaning the specifications can be changed at a whim.
Next to go is RSS 1.0. Although it is useful, and being RDF based can be part of the semantic web, it is more complicated than the other versions. As such, we are left with RSS 0.9x and RSS 2.0. It makes most sense to go for RSS 2.0, since this is the latest version.
Before we begin learning to write an RSS 2.0 feed, lets take a look at a basic example:
<?xml version="1.0" encoding="ISO-8859-1" ?>
<rss version="2.0">
<channel>
<title>Title of the Feed</title>
<link>http://www.example.com</link>
<description>This is an example of an RSS 2.0 feed.</description>
<language>en-gb</language>
<copyright>The copyright notice</copyright>
<item>
<title>An Item in The Feed</title>
<link>http://www.example.com/news.html</link>
<description>This is an example of an item in an RSS 2.0 Feed.</description>
<pubDate>Thu, 03 Sep 2005 17:00:00 GMT</pubDate>
</item>
</channel>
</rss>