Instance parsing of XML DOM object methods

Y2J
Release: 2017-05-08 10:03:36
Original
2039 people have browsed it

async attribute
Function Use
The async attribute indicates whether asynchronous downloading is allowed.
Basic syntax
boolValue = XMLDocument.async; is True; otherwise, it is False.

Example
xmlDoc.async="false";
alert(xmlDoc.async);

attribute attribute
Use
Return the current node's Property list.
Basic syntax
objAttributeList = xmlNode.attributes;

Description
Return an object. If this node cannot contain attributes, a null value is returned.

Example
objAttList = xmlDoc.documentElement.attributes;
alert(objAttList);

childNodes attribute
Function
Returns a node list, including All available child nodes of this node.
Basic syntax
objNodeList=node.childNodes;

Says
Pass back an object. If this node has no child nodes, return null.

Example
objNodeList = xmlDoc.childNodes;
alert(objNodeList);

doctype attribute
Function
Returns the file type node, including the current
DTD
of the file. This node is a general file type declaration, for example, node, and a node object named
EMAIL will be returned. Basic syntax objDocType=xmlDocument.doctype;
Description
Returns a
object
, this attribute is read-only. If this file does not contain a DTD, null will be returned.
Example objDocType = xmlDoc.doctype;
alert(objDocType.nodeName);

documentElement attribute

[Related recommendations]

1.
XML Free Video Tutorial

2.XML Technical Manual

##3.Li Yanhui XHTML Video Tutorial

The above is the detailed content of Instance parsing of XML DOM object methods. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
xml
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template