[whatwg] some comments on DOM collections

On Thu, 19 Oct 2006, Joao Eiras wrote:
> 
> From
> http://www.w3.org/TR/2001/WD-DOM-Level-2-HTML-20011025/html.html#ID-33262535
> item
>   This method retrieves a node specified by ordinal index. Nodes are numbered
> in tree order (depth-first traversal order).
> Parameters
>   index of type unsigned long - The index of the node to be fetched. The index
> origin is 0.
> Return Value
>   Node - The Node at the corresponding position upon success. A value of null
> is returned if the index is out of range.
> 
> This is the best thing to do, from my multiple experiences with ecmascript.

Yeah, this is (mostly) what browsers do, and is what I've made the DOM5 
HTML spec require now.

Cheers,
-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

Received on Thursday, 19 October 2006 15:00:20 UTC