- From: Joao Eiras <joao.eiras@gmail.com>
- Date: Thu, 19 Oct 2006 15:22:21 +0100
Anne van Kesteren <fora at annevankesteren.nl> escreveu: > * Error handling needs to be defined for HTMLCollection.item() and > HTMLCollection.namedItem(). What happens if there's no such indexth node > or node with that id? This also applies to HTMLFormControlsCollection and > HTMLOptionsCollection. 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.
Received on Thursday, 19 October 2006 07:22:21 UTC