Java--xml

Source: Internet
Author: User

xml--describing web content from a data perspective
XML originates from Sgml,xml, a language that can define other languages.
XML documents use self-describing and simple syntax, and the most basic components of an XML document include declarations, processing, directives, and elements.
Example:

<?xml version =  "1.0"  encoding  =  "GB2312"?><?xml-stylesheet type =  "text/xsl"  href =  " Studets.xls "? ><books>    <book bn =  "001" >         <name>java Getting Started </name>        <author > Zhao da </author>        <publisher> Tsinghua University Press </publisher >        </book>    <book bn  =  "002" >        <name> cases </name>         <author> Money Two </author>        </publisher>    </book></books>, University Press of  <publisher> electronic industry; 

The XML declaration--xml declaration is one of the directives, which can be added without the optional content shown in the file. The XML declaration requires that you include the Version property, which is named as the number of the XML being used.
The XML element--xml element consists of the starting tag, the closing tag, and the data content between the tags, multiple elements can be nested, the XML markup is the size of the West, and each tag can contain any number of attributes.
The markup in the XML attribute--xml element can contain any number of attributes. The tag attributes are in the form of a name/value pair, with an equal sign "=" link between the name and the value.
XML annotations-in XML, the annotation method is completely different from HTML, with "<!--" and "--" containing the comment content, instance:
<!--An example of an XML comment--


Zhongzhiyuan Nanjing 904727147, Jiangsu

Java--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.