HTML and CSS Reference
In-Depth Information
Listing 8-45. Copyright Information in Atom
<rights>Copyright © 2014 Leslie Sikos. All rights reserved.</rights>
The source Element
If an entry is derived from an external Atom news feed, the metadata of the original entry can optionally be used as
the subelements of the source element. The author , contributor , rights , and category elements should always
be preserved.
The subtitle Element
Atom feeds can be described by a string provided as the content of a subtitle element, which provides a longer
description than the title element (Listing 8-46).
Listing 8-46. The Description of an Atom News Feed
<title type="text">Leslie Sikos News</title>
<subtitle>
The news feed of Leslie Sikos. Web design news, publications, and more.
</subtitle>
The summary Element
A short description can be added to each Atom entry with the summary element (Listing 8-47).
Listing 8-47. A Summary of an Atom Entry
<summary>The W3C released the updated specification of HTML5.</summary>
RSS or Atom?
Both RSS and Atom are widely supported in all major consumer feed readers. From the standards points of view,
the RSS 2.0 specification is copyrighted by Harvard University and is considered finalized. Significant changes are
unlikely, although the specification was released under the Creative Commons license. In contrast, Atom 1.0 is a more
feature-rich syndication format which can easily be extended.
The Internet media type application/rss+xml is unregistered while application/atom+xml is registered by IANA.
In contrast to RSS 2.0, which supports the RSS document format only, the Atom Entry documents of the Atom
news feeds can apply any network protocol. As a result, the aggregation and extraction of Atom news feeds have more
possibilities.
Although the namespace of RSS 2.0 is not an XML namespace, it can optionally contain elements from external
XML namespaces (as discussed earlier). The namespace of Atom 1.0 is an XML namespace itself and might also have
elements and attributes from other XML namespaces. The implementation of these external elements and attributes
is clearly defined by specification guidelines. It can be concluded that Atom is more extensible than RSS.
RSS does not support relative URIs, while Atom reuses the xml:base attribute, which allows relative references.
There is no schema defined in RSS 2.0. Atom 1.0 applies the RelaxNG schema, which is the non-normative
ISO-standard ISO/IEC 19757-2:2008 [25]. It can be used to validate the data provided in the Atom news feed.
Optionally, further schemas can be generated from RelaxNG.
Correctly written RSS and Atom files are well-formed XML files that can be processed in many ways and can be
extended using the namespace mechanism. Users usually do not notice the difference between the two formats when
using a feed reader application.
 
Search WWH ::




Custom Search