W3C home > Mailing lists > Public > www-validator@w3.org > July 2001

Re: HTML ID case question

From: Eric Meyer <emeyer@netscape.com>
Date: Thu, 12 Jul 2001 12:57:02 -0400
Message-ID: <3B4DD6DE.4090001@netscape.com>
To: www-validator@w3.org
CC: Robert Clary <bclary@netscape.com>
Steven Pemberton wrote:

>Alright, well we discussed this today, and we do have a position, and the
>good news is: nothing is broken, neither the spec, your code base, nor the
>IDs are indeed case insensitive. And documents may not contain IDs that only
>differ in case. That is what section 12.2.1 of HTML 4.01 says.
>This means if you have a URL "#GoOn", then it may only reference an element
>with id="GoOn", and not one with id="Goon" or id="goon".
>However, a document may not contain elements where one has id="GoOn" and
>another with id="Goon".
>So the validator is allowed to complain about your test document, because it
>has an id1 and an ID1, but you don't have to change your code base, and we
>don't have to change our spec.
>It is weird, but it's OK. No one has to fix anything!
   Ah, I see it now.  It's icky, but as you say, there it is, and if one 
splits the right hairs you get such a result.  (Not that I mean to 
criticize, since one must often split hairs to interpret specifications, 
and I've done so many times in the past while working with CSS.)  Still, 
I'd like to VERY strongly recommend that this error get an 
"explanation..." link in the validator results.  The link can point 
straight to the 12.2.1 of HTML 4, that's fine, just so long as it points 
somewhere that authors can use to understand how and why IDs (which are 
claimed to be case-sensitive in one place) can cause trouble when 
there's a case-insensitive match.

Eric A. Meyer ......................... emeyer@netscape.com
Standards Evangelist .................. http://developer.netscape.com/
TE/DS Team, Netscape Communications ... http://www.netscape.com/
Try the new Netscape 6.1 Preview Release!
Received on Thursday, 12 July 2001 12:57:24 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:58:22 UTC