W3C home > Mailing lists > Public > www-style@w3.org > February 2008

[css-3-namespace] Example XML

From: Christof Hoeke <csad7@t-online.de>
Date: Tue, 19 Feb 2008 20:22:13 +0100
Message-ID: <47BB2C65.8060308@t-online.de>
To: Www-style <www-style@w3.org>


Regarding the example at 
http://dev.w3.org/csswg/css3-namespace/#css-qnames, would the following 
selection example be as specified?

     Given the namespace declarations:

     @namespace toto "http://toto.example.org";
     @namespace "http://example.com/foo";

     In a context where the default namespace applies

         represents the name A in the http://toto.example.org namespace.
         represents the name B that belongs to no namespace.
         represents the name C in any namespace, including no namespace.
         represents the name D in the http://example.com/foo namespace.


     Given the following example XML:

     <example xmlns="http://example.com/foo"
         <b xmlns="">2</b>
         <d xmlns="http://toto.example.org">4</d>
         <t2:e xmlns:t2="http://toto.example.org">5</t2:e>

     the following selectors using * as element name would represent

         would select the elements containing 3, 4 and 5
         would select the element containing 2
         would select the elements containing 1, 2, 3, 4, 5  and the 
root element "example"
         would select the elements containing 1 and the root element 

I think I have all possible combinations (at least for elements) and 
maybe adding an example like this would clarify namespaces in CSS even 

Received on Tuesday, 19 February 2008 19:22:44 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:34 UTC