RSS - Version 0.91 Tags and Syntax



Here is the structure of an RSS 0.91 document:

<?xml version="1.0"?>
<!DOCTYPE rss 
   PUBLIC "-//Netscape Communications//DTD RSS 0.91//EN" 
   "http://my.netscape.com/publish/formats/rss-0.91.dtd">
    
   <rss version="0.91">
      <channel>
      <title>...</title>
      <link>...</link>
      <description>...</description>

      <language>...</language>
      <rating>...</rating>
      <copyright>...</copyright>

      <pubDate>...</pubDate>
      <lastBuildDate>...</lastBuildDate>
      <docs>...</docs>

      <managingEditor>...</managingEditor>
      <webMaster>...</webMaster>

      <skipHours>
         <hour>...</hour>
      </skipHours>

      <skipDays>
         <day>...</day>
      </skipDays>

      <image>
         <title>...</title>
         <url>...</url>
         <link>...</link>

         <width>...</width>
         <height>...</height>
         <description>...</description>
      </image>

      <item>
         <title>...</title>
         <link>...</link>
         <description>...</description>
      </item>

      <!-- More item tags -->
      <textInput>
         <title>...</title>
         <description>...</description>
         <name>...</name>
         <link>...</link>
      </textInput>

      </channel>
   </rss>

Here is the detail of all the optional and mandatory tags related to RSS 0.91. Check out the given example to prepare an RSS v0.91 Feed for your website.

NOTE: All the tags are case-sensitive and should be used carefully.

Here is the list of all the optional and mandatory tags related to RSS 0.91.

XML Version Identifier

As an XML application, an RSS document is not required to begin with an XML declaration. It should start with XML version identifier tag.

Syntax

  • <?xml version="1.0"?> or
  • <?xml version="1.0" encoding="[ encoding code here ]"?>

Here is a list of RSS v0.91 Supported Encodings.

Required

Always and exact. Optional encoding attribute (default is UTF-8).

Document Type Identifier

Similar to a valid XHTML document, it is required to specify a document type.

Syntax

<!DOCTYPE rss PUBLIC "-//Netscape Communications//DTD RSS 0.91//EN"
   "http://my.netscape.com/publish/formats/rss-0.91.dtd">

Required

Always and exact.

Max Length

500 characters.

RSS Version Identifier:

Syntax

<rss version="0.91">

Required

Always and exact.

Max Length

500 characters.

Start Channel Tag

There should be one channel start tag in each RSS0.91 File.

Syntax

<channel>

Required

Required. Maximum 1 per RSS file.

Channel Title

An identifying string for a resource. When used in an item, this is the name of the item's link. When used in an image, this is the Alt text for the image. When used in a channel, this is the channel's title. When used in a textinput, this is the textinput's title.

Syntax

<title>TutorialsPoint</title>

Required

Required.

Max Length

1-100 characters.

Channel Description

A channel will have a description tag as described below:

Syntax

<description>Your source for tutorials, references and manuals!</description>

Required

Required.

Max Length

1-500 characters.

Channel Title Link (URL)

This is the link to your homepage and required for a channel.

Syntax

<link>http://www.tutorialspoint.com</link>

Required

Required.

Max Length

1-500 characters.

Channel Language

It specifies the language of your channel (website).

Syntax

<language>[ language code here ]</language>

Here is a list of RSS v0.91 Supported Languages.

Required

Required.

Max Length

2-25 characters.

Channel Rating

For a complete detail on how to use Channel Rating, let us now check how to use PICS Ratings.

Syntax

<rating>[ PICS rating here ]</rating>

Required

Optional. Maximum 1 per channel.

Max Length

20-500 characters.

Copyright Identifier

This tag is allowed in an RSS 0.91 file, but Netcenter does not actually use this tag or its data. The RSS 0.91 format supports this tag for the benefit of other sites that might make use of the tag and its data.

Syntax

<copyright>Copyright 2007, TutorialsPoint</copyright>

Required

Optional and ignored by Netcenter. Maximum 1 per channel.

Max Length

1-100 characters.

Publication Date

This tag is allowed in an RSS 0.91 file, but Netcenter does not actually use this tag or its data. The RSS 0.91 format supports this tag for the benefit of other sites that might make use of the tag and its data.

Syntax

<pubDate>Thu, 19 Jul 2007 07:00:00 GMT</pubDate>

Required:

Optional and ignored by Netcenter. Maximum 1 per channel.

Max Length

1-100 characters.

Last Build Date

This tag is allowed in an RSS 0.91 file, but Netcenter does not actually use this tag or its data. The RSS 0.91 format supports this tag for the benefit of other sites that might make use of the tag and its data.

Syntax

<lastBuildDate>Thu, 19 Jul 2007 16:20:26 GMT </lastBuildDate>.

Required

Optional and ignored by Netcenter. Maximum 1 per channel.

Max Length

1-100 characters.

External Channel Description File (URL)

This tag is allowed in an RSS 0.91 file, but Netcenter does not actually use this tag or its data. The RSS 0.91 format supports this tag for the benefit of other sites that might make use of the tag and its data.

Syntax

<docs>http://my.userland.com/stories/storyReader$11</docs>

Required

Optional and ignored by Netcenter. Maximum 1 per channel.

Max Length

1-500 characters.

Managing Editor

This tag is allowed in an RSS 0.91 file, but Netcenter does not actually use this tag or its data. The RSS 0.91 format supports this tag for the benefit of other sites that might make use of the tag and its data.

Syntax

<managingEditor>mohtashim@tutorialspoint.com</managingEditor>

Required

Optional and ignored by Netcenter. Maximum 1 per channel.

Max Length

1-100 characters.

Webmaster

This tag is allowed in an RSS 0.91 file, but Netcenter does not actually use this tag or its data. The RSS 0.91 format supports this tag for the benefit of other sites that might make use of the tag and its data.

Syntax

<webMaster>mohtashim@tutorialspoint.com</webMaster>

Required

Optional and ignored by Netcenter. Maximum 1 per channel.

Max Length

1-100 characters.

Start Skip Hours Tag

A list of <hours> indicating the hours in the day, GMT, when the channel is unlikely to be updated. If this sub-item is omitted, the channel is assumed to be updated hourly.

Syntax

<skipHours>

Required

Optional, Ignored by Netcenter. Maximum 1 per channel.

Hour

If you are using skipHours tag then it is required to use this tag as well.

Syntax

<hour>7</hour>

Required

Required, if <skipHours>. Maximum 24 per <skipHours>. element.

Max Length

Numeric Value: 0 - 23

End Skip Hours

If you are using skipHours tag then it is required to use this tag as well.

Syntax:

</skipHours>

Required

Required, if <skipHours>.

Start Skip Days Tag

A list of <days> of the week, in English, indicating the days of the week when your channel will not be updated.

Syntax

<skipDays>

Required

Optional, Ignored by Netcenter. Maximum 1 per channel.

Day

If you are using skipDays tag then it is required to use this tag as well.

Syntax

<day>Monday</day>

Required

Required, if <skipDays>. Maximum 7 per <skipDays>. element.

Max Length

1-10 characters

End Skip Days

If you are using skipDays tag, then it is required to use this tag as well.

Syntax

</skipDays>.

Required

Required, if <skipDays>.

Start Image Tag

You can have one image start tag inside a channel.

Syntax

<image>

Required

Optional. Maximum 1 per channel.

Image ALT Text

If you are using image tag, then it is required to use this tag as well.

Syntax

<title>TutorialsPoint Logo</title>

Required

Required, if <image> tag is available.

Max Length

1-500 characters.

Image Location (URL)

Location to load a resource from. Note that this is slightly different from the link tag, which specifies where a user should be re-directed to if a resource is selected.

Syntax

<url>http://www.tutorialspoint.com/images/to-logo.gif</url>

Required

Required, if <image> tag is available.

Max Length

1-500 characters.

Image Link (URL)

If you are using image tag then it is required to use this tag as well.

Syntax

<link>http://www.tutorialspoint.com/</link>

Required

Optional, if <image> tag is available.

Max Length

1-500 characters.

Image Width

If you are using image tag then it is optional to use this tag.

Syntax

<width>[ numeric value here ]</width>

Required

Optional, if <image> tag is available.

Max Length

Numeric Value: 1-144 (Default is 88).

Image Height

It is an optional tag.

Syntax

<height>[ numeric value here ]</height>

Required

Optional, if <image> tag is available.

Max Length

Numeric Value: 1-400 (Default is 31).

Image Description

If you are using image tag, then it is optional to use this tag.

Syntax

<description>Articles, discussions, builds, and more...</description>

Required

Optional, if <image> tag is available.

Max Length

1-100 characters.

End Image Tag

If you are using image tag then it is required to use this tag as well.

Syntax

</image>

Required

Required, if <image> tag is available.

Start Item Tag

This is an optional tag and you can have 0-15 item tags with-in a channel tag.

Syntax

<item>

Required

Optional. 0-15 items allowed per channel.

Item Title

If you are using title tag, then it is required to use this tag as well.

Syntax

<title>Learning RSS</title>

Required

Required, if <title> tag is available.

Max Length

1-100 characters.

Item Link (URL)

If you are using title tag, then it is required to use this tag as well.

Syntax

<link>http://www.tutorialspoint.com/rss/index.htm</link>

Required

Required, if <title> tag is available.

Max Length

1-500 characters.

Item Description

If you are using title tag then it is optional to use this tag as well.

Syntax

<description>RSS Tutorials Online. Read more about it in this discussion...</description>

Required

Optional, if <title> tag is available.

Max Length

1-500 characters.

End Item Tag

If you are using title tag, then it is required to use this tag as well.

Syntax

</item>

Start Text Input Tag

An input field for the purpose of allowing users to submit queries back to the publisher's site. This element should have a title, a link (to a cgi or other processor), a description containing some instructions, and a name, to be used as the name in the HTML tag <input type=text name="[name]">.

Syntax

<textInput>

Required

Optional. Maximum 1 per channel.

Text Input Title (Label of Submit Button)

If you are using textInput tag then it is required to use this tag as well.

Syntax

<title>Send</title>

Required

Required, if <textInput> tag is available.

Max Length

1-100 characters.

Text Input Description

If you are using textInput tag, then it is required to use this tag as well.

Syntax

<description>Comments about TutorialsPoint?</description>

Required

Required, if <textInput> tag is available.

Max Length

1-500 characters.

Text Input Name

If you are using textInput tag then it is required to use this tag as well.

Syntax

<name>[ value of name= attribute of input tag here ]</name>

Required

Required, if <textInput> tag is available.

Max Length

1-20 characters.

Text Input Link

This is the link to the script, which will the process passed data. If you are using textInput tag, then it is required to use this tag as well.

Syntax

<link>http://www.tutorialspoint.com/cgi-bin/sampleonly.cgi</link>

Required

Required, if <textInput> tag is available.

Max Length

1-500 characters.

End Text Input Tag

If you are using textInput tag, then it is required to use this tag as well.

Syntax

<textInput>

Required

Required, if <textInput> tag is available.

End Channel Tag

One end channel is required for a channel start tag.

Syntax

</channel>

Required

Required.

End RSS Tag

This is the closing tag for an RSS0.91 document.

Syntax

</rss>

Required

Required.

Using Special Characters and HTML Entities

Although an RSS 0.91 file is an XML document, RSS 0.91 extends XML by supporting a full set of HTML entities. If you want to use special characters such as ampersands (&) in <url> or <link> tags, you must substitute the appropriate decimal or HTML entities for those characters.

Check for a complete set of HTML entities in out HTML tutorial.

RSS v0.91 Example Feed

Here is an example that shows how to write RSS Feed using version 0.91.

<?xml version="1.0"?>

<!DOCTYPE rss PUBLIC "-//Netscape Communications//DTD RSS 0.91//EN"
   "http://my.netscape.com/publish/formats/rss-0.91.dtd">

<rss version="0.91">

   <channel>
      <title>TutroialsPoint</title>
      <link>http://www.tutorialspoint.com</link>

      <description>
         Online Tutorials and Reference Manuals.
      </description>

      <language>en-us</language>

      <rating>
         (PICS-1.1 "http://www.rsac.org/ratingsv01.html" l 
         gen true comment "RSACi North America Server" for 
         "http://www.rsac.org" on "1996.04.16T08:15-0500" 
         r (n 0 s 0 v 0 l 0))
      </rating>

      <image>
         <title>TutroialsPoint</title>
         <url>http://www.tutorialspoint.com/images/to-logo.gif</url>
         <link>http://www.tutorialspoint.com</link>

         <width>88</width>
         <height>31</height>

         <description>
            Tutorials, Articles, discussions,and more...
         </description>
      </image>

      <item>
         <title>RSS Tutorials</title>
         <link>http://www.tutorialspoint.com/rss/index.htm</link>

         <description>
            Learn RSS in simple and easy steps.
         </description>
      </item>

      <item>
         <title>PHP Tutorials</title>
         <link>http://www.tutorialspoint.com/php/index.htm</link>
         
         <description>
            Learn PHP in simple and easy steps.
         </description>
         
      </item>

      <textInput>
         <title>Send</title>
         <description>Comments about TutoprialsPoint</description>
         <name>responseText</name>
         
         <link>
            http://www.tutorialspoint.com/cgi-bin/tp-contact.cgi
         </link>
         
      </textInput>

   </channel>

</rss>

RSS 0.91 File Extension

A specific file-extension for an RSS 0.91 document is not required. Either .rdf or .xml is recommended, the former being preferred.

RSS 0.91 DTD

Check the following link RSS 0.91 DTD.

rss-feed-formats.htm
Advertisements