note 99324 deleted from domxpath.query by danbrown
| From: | danbrown@php.net | Date: | Tue, 10 Aug 2010 21:22:19 +0000 |
| Subject: | note 99324 deleted from domxpath.query by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-171556@lists.php.net to get a copy of this message | ||
Note Submitter: alan at hcibook dot com
----
The behaviour reported by khaz below is not an error in DOMXPath, but in fact perfectly correct.
In http://www.w3.org/TR/xpath/
// means "descendents of the root"
.// means "descendants of the context node"
query() is not ignoring the contextnode, it is just that some XPath expressions are relative to the
contextnode and others (such as those starting '/' or '//') relative to the root