|
Example 1 - generating an RSS feed from your own page using HTML comment tags | Home | RSSxl | RSSxl tutorial | Support forums | |
If you are generating an RSS feed from your own Web Page, then the easiest method is to insert HTML Comment Tags to identify the feed items.
The following box shows some of the HTML for the examples.htm page on this site:
<h1>Tutorial</h1> <h2>Introduction</h2> <p>You have three options open to you, depending on whether you can edit the HTML on the target page, and depending on whether you are familiar with Regular Expression syntax.</p> <!-- start feed --> <!-- start item --> <h2><a href="example1.htm">Example 1</a></h2> <!-- start description --> <p>This is an example of generating a feed from your own page by inserting HTML comments to identify feed items.</p> <p>This is the easiest method of converting your own web pages.</p> <!-- end description --> <!-- end item --> <!-- start item --> <h2><a href="example2.htm">Example 2</a></h2> <!-- start description --> <p>This is an example of generating a feed from a page using existing HTML tags on the page to identify feed items.</p> <!-- end description --> <!-- end item --> <!-- start item --> <h2><a href="example3.htm">Example 3</a></h2> <!-- start description --> <p>This is an example of generating a feed from your own page using some regular expression syntax to identify feed items.</p> <!-- end description --> <!-- end item --> |
Comment tags have been included in the HTML to mark the start of the feed items, the start and end of each item, and the start and end of each item description. (If pages are generated using a template, these tags can usually be included in the template.) The choice of wording in the comment tags is entirely your own, so if there are existing tags in the right place in your pages, you can use those. In the RSSxl tool, type in the following parameters:
| Page URL = | http://www.wotzwot.com/examples.htm |
| Start String = | <!-- start feed --> |
| Start Item String = | <!-- start item --> |
| End Item String = | <!-- end item --> |
| Start Description String = | <!-- start description --> |
| End Description String = | <!-- end description --> |
Click here to enter these parameters into RSSxl
(Then click on the "Generate RSS" button to see the RSS feed)
Note that in this example the "Start String" could be left blank, because there are no other matches on the page to the "Start Item String" and "End Item String". Also, the "Start Description String" and "End Description String" could also be left blank, because RSSxl will automatically split each item into a Title and Description based on the page layout.