W3C home > Mailing lists > Public > public-webapps@w3.org > October to December 2009

[selectors-api] querySelector with namespace

From: Jonathan Watt <jwatt@jwatt.org>
Date: Thu, 26 Nov 2009 12:18:30 +0100
Message-ID: <4B0E6406.3060404@jwatt.org>
To: public-webapps@w3.org

During a discussion about xml:id I was about to make the throw away comment that
you could use querySelector to easily work around lack of support for xml:id,
but on checking it turns out that's not the case. querySelector, it seems,
cannot be used to select on a specific namespace, since you can only use
namespace prefixes in selectors, and querySelector does not resolve prefixes.

Maybe the working group could consider adding some sort of "non-prefix"
namespace support to selectors for the sake of querySelector/querySelectorsAll,
something like:






I imagine this would be much more widely useful than just for xml:id of course.

Received on Thursday, 26 November 2009 11:18:28 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 20 October 2015 13:55:30 UTC