Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • In XML::RSS "permaLink" holds the guid URL if isPermaLink is true, and "guid" holds it if it is false.

    Sounds like bad API design to me. permaLink should always be the permalink, if there is one, and guid should always be the GUID, if there is one. How this is specified in the wire format is something the API should not expose.

    I don’t know if you’re at liberty to make such changes, though.

    (In fact, I boggle at the effort you’re putting into a module for RSS… Atom’s

    • Sounds like bad API design to me. permaLink should always be the permalink, if there is one, and guid should always be the GUID, if there is one. How this is specified in the wire format is something the API should not expose.

      It is bad API design in my opinion. But this was the API since XML::RSS 1.05 [cpan.org]. BTW, in RSS 2.0 what happens is that the guid element has an isPermaLink attribute which can be "true" or "false". If it is true, then permaLink will hold the contents of the "guid" tag, and if it's false then "guid" will.

      I don’t know if you’re at liberty to make such changes, though.

      Not at the moment, no.

      In fact, I boggle at the effort you’re putting into a module for RSS… Atom’s where it’s at, nowadays. Though I guess we need solid code for consuming the RSS that’s sadly already around.)

      Indeed. I didn't take a close look at Atom yet. But I'm making use of XML::RSS personally and so do many other people who generate or parse the various versions of RSS. My work on XML::RSS started when I saw that a feed I generated did not validate, and decided to fix it. Since then it's been quite an obsession for me to work on it in my copious time.