[Javascript] adding numerics in a table column
Nick Fitzsimons
nick at nickfitz.co.uk
Wed Apr 18 09:51:29 CDT 2007
On 18 Apr 2007, at 15:36:50, Peter Brunone wrote:
> Beyond that, getElementsByTagName does not get an element by
> its NAME attribute; instead, it gets all elements of that tag
> type. For example, getElementsByTagName("SPAN") would get an array
> of all SPAN elements. I suggest giving your objects ID attributes
> and using document.getElementById instead, since this will grab a
> reference to one and only one element.
Alternatively, the "getElementsByName" method will get all elements
having a given value for the "name" attribute, although it should be
used with caution, as Internet Explorer, for reasons best known to
itself, will also return any element that has the same value for its
"id" attribute.
Regards,
Nick.
--
Nick Fitzsimons
http://www.nickfitz.co.uk/
More information about the Javascript
mailing list