RSS 1.0 and 2.0 frustrations
Oct. 18th, 2007 10:08 amHere's a sample RSS 1.0 feed:
Now, here's a sample RSS 2.0 feed:
Now... note the location of the <channel> tags... in the first example, they surround the table of contents, but not the individual items. In the second example, they surround the complete list individual items.
It took me over an hour to note this subtle difference yesterday, as I was trying to figure out why my program-generated RSS feeds were not being parsed properly. Argh.
Other than that, I do like the fact that RSS 2.0 is far more compact than 1.0.
<?xml version="1.0"?>
<rdf:RDF
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns="http://purl.org/rss/1.0/">
<channel rdf:about="http://www.xml.com/xml/news.rss">
<title>XML.com</title>
<link>http://xml.com/pub</link>
<description>
XML.com features a rich mix of information and services
for the XML community.
</description>
<items>
<rdf:Seq>
<rdf:li rdf:resource="http://xml.com/pub/2000/08/09/xslt/xslt.html" />
<rdf:li rdf:resource="http://xml.com/pub/2000/08/09/rdfdb/index.html" />
</rdf:Seq>
</items>
<textinput rdf:resource="http://search.xml.com" />
</channel>
<item rdf:about="http://xml.com/pub/2000/08/09/xslt/xslt.html">
...
</item>
<item rdf:about="http://xml.com/pub/2000/08/09/rdfdb/index.html">
...
</item>
</rdf:RDF>Now, here's a sample RSS 2.0 feed:
<?xml version="1.0"?>
<rss version="2.0">
<channel>
<title>Liftoff News</title>
<link>http://liftoff.msfc.nasa.gov/</link>
<description>Liftoff to Space Exploration.</description>
<item>
...
</item>
<item>
...
</item>
</channel>
</rss>Now... note the location of the <channel> tags... in the first example, they surround the table of contents, but not the individual items. In the second example, they surround the complete list individual items.
It took me over an hour to note this subtle difference yesterday, as I was trying to figure out why my program-generated RSS feeds were not being parsed properly. Argh.
Other than that, I do like the fact that RSS 2.0 is far more compact than 1.0.
(no subject)
Date: 2007-10-19 12:10 am (UTC)(Hint: you can put the item tags inside the channel if you want.)
(no subject)
Date: 2007-10-20 09:23 pm (UTC)Ahhh... I noticed the lack of RDF tags but it did not click.
Any idea why they dropped RDF for v2?
Also, why aren't you here at FurFright? :-)
(no subject)
Date: 2007-10-20 11:05 pm (UTC)Because it's in Conneticut.
(no subject)
Date: 2007-10-20 11:13 pm (UTC)Okay, makes sense.
No excuses!