Rss Syntax
# RSS Syntax
* * *
The RSS 2.0 syntax is simple and strict.
* * *
## How RSS Works
RSS is used to share information between websites.
With RSS, you register your content with a company called an aggregator.
One of the steps involved is creating an RSS document and saving it with the .xml extension. Then upload this file to your website. Next, register with an RSS aggregator. Every day, the aggregator visits the registered websites to search for RSS documents, validates their links, and displays information about the feeds so that customers can link to documents that interest them.
Tip: Please browse free RSS aggregator services in the (#) section.
* * *
## RSS Example
RSS documents use a simple, self-describing syntax.
Letβs look at a simple RSS document:
Home Page Free programming tutorials RSS Tutorial RSS Tutorial XML Tutorial XML Tutorial
The first line in the document: the XML declaration β defines the XML version and character encoding used in the document. This example conforms to the 1.0 specification and uses the UTF-8 character set (which supports Chinese characters).
The next line is the RSS declaration identifying this document as an RSS document (in this case, RSS version 2.0).
The following line contains the `` element. This element is used to describe the RSS feed.
The `` element has three required child elements:
* `` β defines the title of the channel. (e.g., Home Page)
* `` β defines the hyperlink to the channel. (e.g., www.)
* `` β describes the channel (e.g., Free programming tutorials)
Each `` element may contain one or more `` elements.
Each `` element defines an article or βstoryβ within the RSS feed.
The `` element has three required child elements:
* `` β defines the title of the item. (e.g., RSS Tutorial)
* `` β defines the hyperlink to the item. (e.g.,
* `` β describes the item (e.g., RSS Tutorial)
Finally, the last two lines close the `` and `` elements.
* * *
## Comments in RSS
The syntax for writing comments in RSS is similar to that of HTML:
* * *
## RSS Is Written Using XML
Because RSS is also XML, please remember:
* All elements must have closing tags.
* Element names are case-sensitive.
* Elements must be properly nested.
* Attribute values must be quoted.
YouTip