PDA

View Full Version : Dom Menu problem with firefox & Netscape


ccp999
10-11-2005, 06:05 PM
I have a menu using JS to hide and show by calling the getElementByID. Since I use frame and the control buttons and the menu are in different frames and I put the JS in an extenal file. it works fine from IE but not in fireFox and Netscape which all menu are jum together.

code:
...
function showmenu(menu){
parent.subMenuFrame.document.getElementById('hardwares').style.visibility="hidden";
...

But I tried with other case which I put the JS inside the frame page with menu, it works. But the code is:

...
function showmenu(menu){
document.getElementById('hardwares').style.visibility="hidden";
...

How can I fix this?

martin_narg
10-17-2005, 10:50 PM
Have you tried referencing by contentWindow: parent.subMenuFrame.contentWindow.document.getElementById('hardwares').style.visibility="hidden";Hope this helps.

m_n