Is HTML code inside the <description>
tag compliant in RSS 2.0?
The RSS 2.0 specification says that you can include HTML in the description element so long as you properly encode the markup.
How To Display RSS Feed In HTML Website? Step 1: Select HTML as your website platform from the options. Step 2: Set the width and height (or auto) of your feed and click on “Get Code”. Step 3: Copy the given Code and paste it into the back-end of any webpage where you want to display RSS feed.
RSS is a Web content syndication format. Its name is an acronym for Really Simple Syndication. RSS is a dialect of XML. All RSS files must conform to the XML 1.0 specification, as published on the World Wide Web Consortium (W3C) website.
The RSS 2.0 specification says that you can include HTML in the description element so long as you properly encode the markup.
You have two ways to do this:
Convert tags to escaped HTML entities:
<description>this is <b>bold</b></description>
Wrap the description content within a CDATA
section:
<description><![CDATA[this is <b>bold</b>]]></description>
You can decode <
and >
char to html code
<
: <
>
: >
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With