Hi there
I do not whether I should ask be asking this question.
I need to getElementbyid for an object which is already exisiting in the document
. In the example, I would like to get the element "test" which is sub of parentDiv1. Could anyone help? It is ok with ff but not with IE. Any tips?
Example:
<div id="parentDiv1"> <ul id="test1">test</ul> </div> <div id="parentDiv2"> <ul id="test2">test</ul> </div> <script> var prtDiv1 = document.getElementById("parentDiv1"); var test1 = prtDiv1.getElementById("test1"); </script>