- From: Boris Zbarsky <bzbarsky@MIT.EDU>
- Date: Wed, 12 Mar 2008 16:00:45 -0500
- To: liorean <liorean@gmail.com>
- CC: "Web APIs WG (public)" <public-webapi@w3.org>
liorean wrote: > As a disconnected node would not be in the node tree from document, > can it match a query at all? That's a really good question! It seems to match in the webkit nightly I just tried here, as well as in IE8. Simple testcase: javascript:var n = document.createElement("div");n.appendChild(document.createElement("span"));alert(n.querySelector("span").tagName); Paste this into your URL bar of choice. A naive implementation in Gecko would also match such nodes unless they are purposefully excluded. If the intent is that these nodes not match, the spec obviously needs to spell it out a lot more clearly than it currently does. -Boris
Received on Wednesday, 12 March 2008 21:01:10 UTC