Name
item( ) — NN n/a IE 4 DOM n/a
Synopsis
item(index[,
subindex])
Returns a single object or collection of objects corresponding to the element matching the index value (or, optionally, the index and subindex values).
Returned Value
One object or collection (array) of objects. If there are no matches
to the parameters, the returned value is null.
Parameters
-
index When the parameter is a zero-based integer, the returned value is a single element corresponding to the said numbered item in source code order (nested within the current element); when the parameter is a string, the returned value is a collection of elements whose
idornameproperties match that string.-
subindex If you specify a string value for the first parameter, you may use the second parameter to specify a zero-based integer to retrieve a specific element from the collection whose
idornameproperties match the first parameter’s string value.
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access