W3C home > Mailing lists > Public > www-style@w3.org > December 2005

Re: Selectors: section 6.5: Error

From: Ian Hickson <ian@hixie.ch>
Date: Thu, 29 Dec 2005 16:52:55 +0000 (UTC)
To: Elliotte Harold <elharo@metalab.unc.edu>
Cc: www-style@w3.org
Message-ID: <Pine.LNX.4.62.0512291649400.17886@dhalsim.dreamhost.com>

On Thu, 29 Dec 2005, Elliotte Harold wrote:
> 
> Section 6.5 of the selectors draft states,
> 
> "What makes attributes of type ID special is that no two such attributes 
> can have the same value in a document, regardless of the type of the 
> elements that carry them; whatever the document language, an ID typed 
> attribute can be used to uniquely identify its element. "
> 
> I respectfully disagree. Attributes of type ID can and do have the same 
> value. A document in which this occurs would be invalid; but such 
> documents do exist, are well-formed, and can be usefully processed.
> 
> I suggest two things:
> 
> 1. Weaken the first paragraph to make it clear that there is no 
> guarantee that IDs are unique, even if they're supposed to be.

I have rephrased the sentence to say " What makes attributes of type ID 
special is that no two such attributes can have the same value in a 
conformant document...". I will let you know if the working group 
disagrees with this change when it is reviewed.


> 2. Specify what happens when multiple elements share the same ID.

This is already specified: "ID selectors represent an element instance 
based on its identifier", meaning that if the ID of an element is the same 
as the ID of the rule, it matches.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
Received on Thursday, 29 December 2005 16:53:16 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:42 GMT