Forum OpenACS Q&A: Re: Parsing RSS

Collapse
12: Re: Parsing RSS (response to 1)
Posted by Don Baccus on
Oops, Jeff's right, Jerry's stuff didn't parse but rather generated RSS.  Thanks for setting me straight.

I also don't see any reason to use tDOM or ns_xml to generate known XML content.  There's no manipulation to do to the document - where's the justification for the extra step?  It would consume memory and cycles and the code to do so would probably be less readable.

XML is supposed to be human-readable, after all, and that means it's easily written by code-writing humans ...

Collapse
16: Re: Parsing RSS (response to 12)
Posted by John Sequeira on
I had to write a middle tier component to generate an XML site tree for a .NET project early this year,  and started out by assembling a big string.

The front tier folks would occasionally get errors when things like angle brackets showed up in my text.  I found switching to using MS's XML DOM builder useful in avoiding these and similar errors,  because that was what the front tier folks were using to parse it.  After I switched,  when there was an error parsing the file,  I was very confident that it wasn't my code (it never was).

With XML,  since the whole point is data interoperabililty,  I would say that maximizing the odds of this by using something like tDOM would be worthwhile.

Also,  I'm currently using both Amphetadesk and Radio Userland to parse RSS feeds (yes, I'm a news junkie) - they die all the time on people's feeds that aren't valid XML.  From experience,  generating valid XML by design is a very good thing.