ReportingAnalyst
MIS
Hi,
I have a function:
HTML is:
I am calling the top most UL tag with the id "menu" from the function.
In the Java Console, I get an error message:
Object doesn't support this Property or Method at line 90 where line 90 refers to:
What mistake am I making?
Thanks.
I have a function:
Code:
//Get all the links of the UL tag
function collectULLinks() {
var ulObj = document.getElementByID("menu") // id of the first UL tag in the tree.
ulObjLinks = document.getElementsByTagName("a") // <a> tags of the UL tree which are the <a href> tags.
}
HTML is:
Code:
<ul id="menu">
<li>
<input type="radio" checked id="empid" name="empid" value="4655">
<a href="#" class="a_style" onClick="s_Hide('4655')">TopMgr</a>
<ul id="4655" class="ulcontent">
<li>
<input type="radio" id="empid" name="empid" value="2109922">
<a href="#" class="a_style" onClick="s_Hide('2109922'); return false;">Mgr1</a>
<ul id="2109922" class="ulcontent">
<li>
<input type="radio" id="empid" name="empid" value="8693">
Sub1
</li>
<li>
<input type="radio" id="empid" name="empid" value="8793">
Sub2
</li>
<li>
<input type="radio" id="empid" name="empid" value="8893">
Sub3
</li>
</ul>
</li>
......
I am calling the top most UL tag with the id "menu" from the function.
In the Java Console, I get an error message:
Object doesn't support this Property or Method at line 90 where line 90 refers to:
Code:
var ulObj = document.getElementByID("menu") // id of the first UL tag in the tree.
What mistake am I making?
Thanks.