(PHP 5, PHP 7, PHP 8)
$exclusive
= false
,$withComments
= false
,$xpath
= null
,$nsPrefixes
= null
$uri
,$exclusive
= false
,$withComments
= false
,$xpath
= null
,$nsPrefixes
= null
Returns the most accurate name for the current node type
The value of this node, depending on its type.
Contrary to the W3C specification, the node value of
DOMElement nodes is equal to DOMNode::textContent instead
of null
.
Gets the type of the node. One of the predefined XML_xxx_NODE constants
The parent of this node. If there is no such node, this returns null
.
A DOMNodeList that contains all children of this node. If there are no children, this is an empty DOMNodeList.
The first child of this node. If there is no such node, this
returns null
.
The last child of this node. If there is no such node, this returns null
.
The node immediately preceding this node. If there is no such
node, this returns null
.
The node immediately following this node. If there is no such
node, this returns null
.
A DOMNamedNodeMap containing the
attributes of this node (if it is a DOMElement)
or null
otherwise.
The DOMDocument object associated with this node, or null
if this node is a DOMDocument
The namespace URI of this node, or null
if it is unspecified.
The namespace prefix of this node, or null
if it is unspecified.
Returns the local part of the qualified name of this node.
The absolute base URI of this node or null
if the implementation
wasn't able to obtain an absolute URI.
The text content of this node and its descendants.
Version | Description |
---|---|
8.0.0 | The unimplemented methods DOMNode::compareDocumentPosition(), DOMNode::isEqualNode(), DOMNode::getFeature(), DOMNode::setUserData() and DOMNode::getUserData() have been removed. |
Note:
The DOM extension uses UTF-8 encoding. Use mb_convert_encoding(), UConverter::transcode(), or iconv() to handle other encodings.