Some reserved characters in PCDATA are not allowed in the XML document while fetching the data from XML, this will cause an error in the browser.
To avoid this issue, CDATA section is used.
Here’s the syntax of CDATA:
<!CDATA[ // CDATA CODE ]]>
In this guide I will show you how you can include CDATA in an XML feed attribute tag.
Follow the easy steps to includ CDATA in your XML feed attribute tag:
1. At first create a new feed >> select a merchant or open your existing feed.
2. Scroll down to the Feed Configuration section, and here you will find all the attributes as per your selected merchant.
3. Click on the Output Filter dropdown field of the concerned attribute and select “CDATA” from the dropdown list.
4. Finally, go back to the top and click on the publish/ update button to publish/ update the feed.
Now when you open the feed, you will find that the values of the concerned attributes are at within the <!CDATA[ … ]]> tag.