W3C home > Mailing lists > Public > www-style@w3.org > September 2013

[selectors4] List [xml:lang] and [xmlns] as selectors that do not work in XML

From: Leif Halvard Silli <xn--mlform-iua@xn--mlform-iua.no>
Date: Wed, 25 Sep 2013 13:43:16 +0200
To: "www-style@w3.org" <www-style@w3.org>
Message-ID: <20130925134316065514.2620db30@xn--mlform-iua.no>
The section on ‘Attribute selectors and namespaces’ says: [1] 

   [|att] { color: green }
    [att] { color: green }
      [ … snip … ]
   The last two rules are equivalent and will match only elements
   with the attribute att where the attribute is not in a namespace.

Hence, these rules would not work in a namespace aware XML parser:

 	   [xmlns] { color: green }
	[xml:lang] { color: green }

Proposal: Please add a note/info that mentions @xml:foo and @xmlns as 
examples of common attributes that cannot, when occurring in a XML 
document, be styled with a simple [att]{} selector. It helps authors to 
understand the concept if they see an actual, non-theoretical, example.

[1] http://dev.w3.org/csswg/selectors4/#attrnmsp

leif halvard silli
Received on Wednesday, 25 September 2013 11:43:45 UTC

This archive was generated by hypermail 2.4.0 : Monday, 23 January 2023 02:14:32 UTC