in reply to Re^4: RSS feed fixed
in thread RSS feed fixed

For starters, the following stereotypical Newest Nodes stream...
<?xml version="1.0" encoding="ISO-8859-1"?> <NEWESTNODES> <INFO site="http://perlmonks.org/" sitename="Perl Monks" foruser="Anonymous Monk" foruser_id="961" min_poll_seconds="30" style="default" gentimeGMT="2004-09-22 17:22:02" req_from="Tue Sep 21 13:22:02 2004" got_from="Tue Sep 21 13:22:02 2004" lastchecked="20040921132202"> Rendered by the Newest Nodes XML Generator </INFO> <NODE nodetype="perlquestion" author_user="378491" createtime="20040922123043" node_id="392963"> CGI::Session Handling </NODE> <AUTHOR node_id="961"> Anonymous Monk </AUTHOR> </NEWESTNODES>
...could be done in RSS as:
<?xml version="1.0"?> <rss version="2.0" xmlns:perlmonks="http://perlmonks.org/?node_id=3930 +35#"> <channel> <!-- required data: --> <title>Newest Nodes</title> <link>http://perlmonks.org/?node_id=3628</link> <!-- optional data: --> <docs>http://blogs.law.harvard.edu/tech/rss</docs> <!-- RSS 2.0 sp +ec --> <generator>PerlMonks Newest Nodes RSS generator</generator> <lastBuildDate>Wed, 22 Sep 04 16:12:21 GMT</lastBuildDate> <!-- non-standard data: --> <perlmonks:foruser>Anonymous Monk</perlmonks:foruser> <perlmonks:foruser_id>961</perlmonks:foruser_id> <perlmonks:min_poll_seconds>30</perlmonks:min_poll_seconds> <perlmonks:req_from>20040921132202</perlmonks:req_from> <perlmonks:got_from>20040921132202</perlmonks:got_from> <perlmonks:lastchecked>20040921132202</perlmonks:lastchecked> <!-- here all the NODEs: --> <item perlmonks:itemtype="node"> <title>CGI::Session Handling</title> <link>http://perlmonks.org/?node_id=392963</link> <description>My site is using CGI::Session to handle a mem...</des +cription> <perlmonks:node_id>392963</perlmonks:node_id> <perlmonks:createtime>20040922123043</perlmonks:createtime> <perlmonks:nodetype>perlquestion</perlmonks:nodetype> <perlmonks:author_user>378491</perlmonks:author_user> </item> <!-- here all the AUTHORs: --> <item perlmonks:itemtype="author"> <title>Anonymous Monk</title> <link>http://perlmonks.org/?node_id=961</link> <perlmonks:node_id>961</perlmonks:node_id> </item> </channel> </rss>

Yeah, it's a little more verbose, but it's just syntax. Elements in place of attributes, mostly.


Update:

Here's a sample in Atom. I think it's valid, but the format spec hasn't quite been nailed down yet.

<?xml version="1.0" encoding="utf-8"?> <feed version="draft-ietf-atompub-format-02: do not deploy" xmlns="http://purl.org/atom/ns#draft-ietf-atompub-format-02" > <head> <title>Newest Nodes</title> <link rel="alternate" type="text/html" href="http://perlmonks.org/?node_id=3628" /> <modified>2003-12-13T18:30:02Z</modified> <!-- datetimes must conform to RFC-3339 --> <generator>PerlMonks Newest Nodes Atom generator</generator> <!-- non-standard data: --> <perlmonks:foruser>Anonymous Monk</perlmonks:foruser> <perlmonks:foruser_id>961</perlmonks:foruser_id> <perlmonks:min_poll_seconds>30</perlmonks:min_poll_seconds> <perlmonks:req_from>20040921132202</perlmonks:req_from> <perlmonks:got_from>20040921132202</perlmonks:got_from> <perlmonks:lastchecked>20040921132202</perlmonks:lastchecked> </head> <entry> <title>CGI::Session Handling</title> <link rel="alternate" type="text/html" href="http://perlmonks.org/?node_id=392963" /> <!-- replaces createtime: --> <created>2003-12-13T08:29:29Z</created> <!-- see http://taguri.org/draft-kindberg-tag-uri-04.txt --> <id>tag:perlmonks.org,2003:392963</id> <!-- replaces authoruser attribute, and all the AUTHOR entries +: --> <author> <name>Anonymous Monk</name> <uri>http://perlmonks.org/?node_id=961</uri> <id>tag:perlmonks.org,2003:961</id> <!-- not (yet) standar +d? --> </author> </entry> </feed>
In this Atom sample, I've gone a bit further toward being natural, whereas with the RSS I was kinda shoe-horning the existing XML structure into RSS format.