[whatwg] Re: getElementsByClassName

Jim Ley jim.ley at gmail.com
Tue Sep 6 02:39:06 PDT 2005

On 9/6/05, Kornel Lesinski <kornel at ideadesigners.com> wrote:
> On Tue, 06 Sep 2005 00:54:56 +0100, Ian Hickson <ian at hixie.ch> wrote:
> >   document.getElementsByClassName.apply(document, find);
> >
> > ...which seems much better to me than using a string.
> It's the first time I see apply method used. I couldn't find it in
> ECMA262-3 nor in WA1.0. Can you give me a hint where it's defined?

If you can find a definition (as opposed to a description) it'll be in
the Mozilla documentation, it was a JavaScript 1.3 extension to ES,
and even in their description, it doesn't say it applies to host
objects in the ES sense, it certainly doesn't work with host objects
in other implementations.

I certainly can't see what the problem with tokenising a string on
whitespace is, that very code is required throughout browsers, and is
the sort of "my first project" in a CS course...


More information about the whatwg mailing list