$dom->query()
Executes an XPath query in the document
$dom->query(string $query, DOMNode|null $node = null): DOMNodeList|false
Parameters
Name | Type | Default | Description |
---|---|---|---|
$queryrequired | string |
no default value | |
$node | DOMNode ornull |
null
|
Optional context node for relative queries |
Return types
DOMNodeList
orfalse
This method modifies the existing $dom
object it is applied to and returns it again.