![]() |
![]() | ![]() | ![]() | Adding HTML Formatting to RSS FeedsAlthough RSS 2.0 feeds are distributed as XML files, you may have noticed more and more HTML formatting appearing in the feeds you receive. (For an example, click here to view the Altova Developer Connection Newsletter feed.) You can add HTML to the <description> element of RSS feed items in several ways:
Regardless of whether you use the Authentic RSS Input form with Altova Authentic Desktop Edition or with Altova XMLSpy, the Authentic form automatically substitutes the correct entity for each character that would be illegal inside the <description> element. Although the RSS item description is displayed in Authentic View like this:
The underlying content is actually this, as displayed in XMLSpy Text View:
One way to ensure accuracy of the HTML coding entered in your RSS XML feed is to construct and preview the code in an HTML file. XMLSpy supports HTML input with color coding, entry helpers, autocompletion, and preview in the XMLSpy Browser View. While you are creating a new RSS item in one window, you can open a new HTML file to create and preview the HTML content. In XMLSpy Text View, your item coded as HTML might look like this:
You can then copy and paste the relevant portion directly into your Authentic RSS Input form, which would look like this:
Looking at the same RSS item in XMLSpy Text View, we see that all the required entities have been substituted automatically to create error-free content.
As you add HTML to your RSS feed, you should keep several caveats in mind:
Download a free trial of Altova XMLSpy® 2008 to try the techniques described here for yourself! | ![]() |
![]() | ![]() | ||||||||||||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | |||||
|
