W3C home > Mailing lists > Public > www-dom@w3.org > July to September 2001

Re: getElementsByTagName() and case-sensitivity for HTML documents

From: Bob Foster <bob.foster@webgain.com>
Date: Mon, 30 Jul 2001 02:40:12 -0500
Message-ID: <06d901c118ca$e02954b0$66181eac@itools.symantec.com>
To: <www-dom@w3.org>
From: "David Flanagan" <david@oreilly.com>
> As far as I know, the getElementsByTagName() method of the Document and
> Element interfaces does not care what capitalization you use when you
> specify the tag name: it does a case-insensitive compare, or normalizes
> the tag names to all uppercase or all lowercase or something.
> However, I cannot find where the spec  actually says this.   Am I
> missing it somewhere, or does the spec need to be clarified, or am
> I just wrong about the behavior of this method.

I'm kind of hoping you are wrong. XML is case-sensitive. The elements <a>
and <A> are not the same and I don't know why one would want them returned
in the same list.

Bob Foster

>     David Flanagan
Received on Monday, 30 July 2001 03:42:37 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 20 October 2015 10:46:08 UTC