At the time of the blog backup, all articles were exported, the export is an XML document, the article content is in the CDATA section.
The following XML is described in CDATA:
All text in the XML document is parsed by the parser. only the text in CDATA sections (CDATA section) is ignored by the parser.
The term CDATA refers to textual data (unparsed Character data) that should not be parsed by the XML parser. In XML elements, "<" and "&" are illegal.
"<" generates an error because the parser interprets the character as the beginning of the new element. "&" also generates an error because the parser interprets the character as the beginning of the character entity.
Some text, such as JavaScript code, contains a large number of "<" or "&" characters. To avoid errors, you can define the script code as CDATA.
CDATA part by "<! [cdata[] begins with the end of "]]>".
The XML format is as follows:
< Description > <! [cdata[]]></description>< Description><![ cdata[<p> floating-point product after rounding, the number obtained does not match the expected </p>]]></Description >
When working with the PHP processing function simplexml_load_file, the document is processed by default and does not contain the CDATA data section.
<? PHP $filename = ' xx '; $xml simplexml_load_file ($filename); // No CDATA data $xml simplexml_load_file ($filenamenull, Libxml_nocdata); // a third parameter
PHP handles XML documents without CDATA part of data processing