Problem with document.getElementById

Posted by pokrate on Stack Overflow See other posts from Stack Overflow or by pokrate
Published on 2010-04-02T19:46:57Z Indexed on 2010/04/02 19:53 UTC
Read the original article Hit count: 294

Filed under:

Hi,

This works :


alert(document.getElementById("Container").nodeName);

But this doesnt :


var CurParent = document.getElementById("Container");
alert(CurParent.nodeName);

I am using IE7. Why ?

© Stack Overflow or respective owner

Related posts about JavaScript