Menu

#2 Incorrect XPathResult type names

open
nobody
None
5
2007-03-16
2007-03-16
No

Currently, the following types are made available for XPathResults of type SNAPSHOT:

XPathResult.UNORDERED_SNAPSHOT_TYPE = 6;
XPathResult.ORDERED_SNAPSHOT_TYPE = 7;

However according to http://www.w3.org/TR/2004/NOTE-DOM-Level-3-XPath-20040226/xpath.html they should be:

XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE = 6;
XPathResult.ORDERED_NODE_SNAPSHOT_TYPE = 7;

(note the additional _NODE_). I guess for backwards compatibility you could leave in the old and just add the new. But its a real problem to be not using the W3C recommend names. Makes prototype.js's use of XPath fail.

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.