XML differs from html,html for presenting data, and XML for storing and exchanging data.
XML regardless of platform differences, hardware and software differences, as long as the ability to read the operation file, you can process the XML file, the data stored inside the operation. Avoid data format incompatibility and make data exchange between different systems more feasible
1. Note: Entity references, because XML needs to use some symbols as the key to differentiate data, so when you want to use them as characters only when you need the entity reference, and & must use the entity reference, the other best also use.
<< less than >> greater than && and number ' ' Single quote " " quotation marks
2. Note: Spaces in XML are preserved
3.xml Store line wrap in LF
XML Naming conventions
XML elements must follow the following naming conventions:
- Names can contain letters, numbers, and other characters
- Names cannot start with numbers or punctuation marks
- The name cannot start with the character "XML" (or XML, XML)
- Name cannot contain spaces
You can use any name without a reserved word.
XML DTD
The role of a DTD is to define the structure of an XML document. It uses a series of legitimate elements to define the document structure:
PCDATA
PCDATA means the parsed character data (parsed character).
You can think of character data as text between the opening and closing tags of an XML element.
PCDATA is the text that will be parsed by the parser. The text will be examined by the parser entity and tagged.
The labels in the text are treated as tokens, and the entities are expanded.
However, the parsed character data should not contain any &, <, or > characters; you need to use &, < and > Entities to replace them separately.
Cdata
CDATA means character data (character).
CDATA is text that will not be parsed by the parser. the labels in these texts are not treated as tokens, and the entities in them are not expanded.
Reference: http://code727.iteye.com/blog/1882877
http://www.iteye.com/topic/517520
XML Memo DTD PCDATA CDATA