Free WebSchools.com

Google


Blog ForumsLive chat WebhostingLink TO UsSEO ToolsResources


HOME

XML Basic

XML Introduction
XML Basic Tags

XML Validation
XML with CSS
XML CDATA


CDATA



All text in an XML document will be parsed by the parser.

Only text inside a CDATA section will be ignored by the parser.

If you write a character like "<" inside an XML element, it will generate an error.

if age < 10 then



To avoid this, you have to replace the "<" character.

There are 5 predefined entity references in XML:
&lt; < less than
&gt; > greater than
&amp; & ampersand 
&apos; ' apostrophe
&quot; " quotation mark

CDATA


Everything inside a CDATA section is ignored by the parser.
If your text contains a lot of "<" or "&" characters - as program code often does - the XML element can be defined as a CDATA section.
A CDATA section starts with "":





In the example above, everything inside the CDATA section is ignored by the parser.