Re: How to get reference to an object

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Alex D. wrote:
Is an html document. DOM is a tree that can contain different
nodes, like Elements, Attr, Comments, DocumentFragment and Text.
I know the name or ID for the node I need but I dont know how
to reference the node by ID since there's no GetNodeByID
function....just GetElementByID

There is no GetElementByID method. It's getElementById.

ID applies to "All elements but BASE, HEAD, HTML, META, SCRIPT, STYLE,
TITLE". What kind of node *legitimately* has an ID but is not an element?
http://www.w3.org/TR/html401/index/attributes.html



--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms.


.



Relevant Pages

  • Re: Best Way to access Input fields
    ... test of getElementById -vs- form.elements. ... Unsolicited commercial email will be read at a cost of $500 per message. ... of this email address implies consent to these terms. ... question is worth asking, it's worth posting. ...
    (microsoft.public.scripting.jscript)
  • Re: Use of document.all
    ... getElementById. ... Dave Anderson ... Unsolicited commercial email will be read at a cost of $500 per message. ... question is worth asking, it's worth posting. ...
    (microsoft.public.scripting.jscript)
  • Re: Checked checkboxes
    ... There are a number of DOM properties/methods that are ... Are you implying .getElementById() is properly implemented in IE? ... Unsolicited commercial email will be read at a cost of $500 per message. ... If your question is worth asking, ...
    (microsoft.public.scripting.jscript)
  • Re: Converting "document.form" path to using "document.getElementID"
    ... > Can somebody convert this for me, to using getElementByID? ... Unsolicited commercial email will be read at a cost of $500 per message. ... If your question is worth asking, it's worth posting. ...
    (microsoft.public.scripting.jscript)