Basic XML operations

Source: Internet
Author: User

The text in all XML documents will be parsed by the parser.
Only the text in the CDATA section is ignored by the parser.
All content in the CDATA section is ignored by the parser.
CDATA is partly composed of "<! [CDATA ["start from"]> "end:

DTD
Schema

Constraint: XML writing Specification
Define a file as a DTD
Basic Syntax:
+ Indicates one or more
<! Element class (student +)>
<! Element student (name, age, introduction)>
<! Element name (# pcdata)>
<! Element age (# pcdata)>
<! Element introduction (# pcdata)>

Introduce DTD to constrain XML files
<! Doctype note system "note. DTD">

PS: (refer to the header introduced in HTML "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd)
To open this file, a DTD constraint file is returned.
Then write a parsing tool to parse the XML code.
<Script language = "JavaScript">
VaR xmldoc = new activexobject ("Microsoft. xmldom ");
Xmldoc. validateonparse = "true"; // enable verification
Xmldoc. Load ("name. xml ");
<SCRIPT>

JAXP instance
Java performs crud operations on XML

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.