Avoid Using the Same Title Twice


How can RSS readers tell if they've already read an item from your feed? Various readers check in different ways, but one way is by examining the titles of your items when they check your feed. If you re-use the same title for different items in your feed, that could be a problemsome RSS readers might not know the second use of the same title is a new item.

You can also update the <pubDate> element to indicate the date of different RSS itemsmost RSS readers will use that information if you supply it.

      <item>       <title>Steve shovels the snow</title>       <author>steve@rssmaniac.com</author>       <description><![CDATA[It snowed once again.        Time to shovel!]]></description>                <pubDate>Thu, 08 Dec 2005 08:39:51 -0500</pubDate>       <link>http://www.rssmaniac.com/steve</link>      </item>          .          .          . 


You can also use the <guid> element to make each RSS item unique (as discussed in Chapter 4). GUID stands for globally unique identifier, and it is often a unique URL that points to the page for a specific item.

       <item>        <title>Steve shovels the snow</title>        <author>steve@rssmaniac.com</author>        <description><![CDATA[It snowed once again.         Time to shovel!]]></description>        <pubDate>Thu, 08 Dec 2005 08:39:51 -0500</pubDate>        <link>http://www.rssmaniac.com/steve</link>                <guid>http://www.rssmaniac.com/48393.html</guid>       </item>          .          .          . 


Note that not all RSS readers will make use of the <guid> element.



Secrets of RSS
Secrets of RSS
ISBN: 0321426223
EAN: 2147483647
Year: 2004
Pages: 110

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net