Loading ...
Sorry, an error occurred while loading the content.

RE: [RSS-DEV] FW: RSS Feed question

Expand Messages
  • Danny Ayers
    Message Hi I want to generate the rss feed like the below where in I should be able to add custom attributes.I wanted to know whether I can generate the RSS
    Message 1 of 1 , Feb 24, 2004
    • 0 Attachment
      Message


       
       
      Hi I want to generate the rss feed like the below where in I should be able to add custom attributes.I wanted to know whether I can generate the RSS like the below one. 
       
      ----
       
      The correct way of doing this would be to use a custom namespace:
       
       <rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"
      xmlns:rel="http://example.org/ns">
      ...
      <item>
      ...
          <rel:supportedrelease>1,2, 2.1, 3.2</rel:supportedrelease>
       
       
      Where http://example.org/ns is a domain under your control (there doesn't have to be anything on the web there - it's only used as a name).
       
      However, your custom element would only be usable by systems that were explicitly built to understand "rel:supportedrelease". On the other hand, were you to use RSS 1.0, the XML would look very similar:
       
      ...
      ...
          <rel:supportedrelease>1,2, 2.1, 3.2</rel:supportedrelease>
       
       
       but any RDF-based system would be able to determine that  "rel:supportedrelease"was a property of the item identified, a property that could take an RSS item as its subject and a literal string as its object. RSS 2.0 systems don't even know that the element applies to the item, but RSS 1.0 uses RDF/XML, which provides partial understanding of unknown vocabularies.
       
      What's more, if you had defined an RDF schema somewhere stating that "re:supportedrelease" was a subclass of "dc:description", a smarter RDF-based system could display the information in a sensible fashion. 
       
       
      There are some guidelines on adding terms to RSS 1.0 (in "modules") at:
       
      I did a write up of stuff about extending RSS:
       
      Cheers,
      Danny.
       
       
      ////////////////////////////////////////////////////////////////////////////

      <rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
        <channel>
          <title>XML.com</title>
          <link>http://www.xml.com/</link>
          <description>XML.com features a rich mix of information and services for the XML community.</description>
          <language>en-us</language>
          <item>
            <title>Normalizing XML, Part 2</title>
            <link>http://www.xml.com/pub/a/2002/12/04/normalizing.html</link>
            <description>In this second and final look at applying relational normalization techniques to W3C XML Schema data modeling, Will Provost discusses when not to normalize, the scope of uniqueness and the fourth and fifth normal forms.</description>
            <dc:creator>Will Provost</dc:creator>
            <dc:date>2002-12-04</dc:date>   

             <supportedrelease>1,2, 2.1, 3.2</supportedrelease>
          </item>
            </channel>
      </rss>
      ////////////////////////////////////////////////////////////////////

    Your message has been successfully submitted and would be delivered to recipients shortly.