Hi,
I'm trying to assign the "onmouseenter" event programatically with the following code:
function cscript(root) {
for(var i=0;i<root.childNodes.length;i++) {
btn = root.childNodes(i);
if (btn.className.toLowerCase().length > 6) {
chk = btn.className.toLowerCase.substring(0, 7);
} else { chk = "nope"; }
if (chk == "toolbar" || chk == "menubar" {
btn.onmouseenter = mhover(btn);
btn.onmouseleave = mleave(btn);
}
cscript(btn);
}
}
You've probably spotted the error already since I'm a beginner...
I call the script at the end of the page as "cscript(document)".
I have several TD's whose class name is set to "toolbar" and "menubar".
Somehow, if I add an "alert" to tell me all the "class names" that are "walked", I never get a "menubar/toolbar"...
Thanks in advance.
Ivan V.
I'm trying to assign the "onmouseenter" event programatically with the following code:
function cscript(root) {
for(var i=0;i<root.childNodes.length;i++) {
btn = root.childNodes(i);
if (btn.className.toLowerCase().length > 6) {
chk = btn.className.toLowerCase.substring(0, 7);
} else { chk = "nope"; }
if (chk == "toolbar" || chk == "menubar" {
btn.onmouseenter = mhover(btn);
btn.onmouseleave = mleave(btn);
}
cscript(btn);
}
}
You've probably spotted the error already since I'm a beginner...
I call the script at the end of the page as "cscript(document)".
I have several TD's whose class name is set to "toolbar" and "menubar".
Somehow, if I add an "alert" to tell me all the "class names" that are "walked", I never get a "menubar/toolbar"...
Thanks in advance.
Ivan V.