Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Toggle Menu not working in Netscape 4.78 or 6

Status
Not open for further replies.

jewel464g

Technical User
Jul 18, 2001
198
US
The link to the code is here:
This is the code:
<SCRIPT TYPE = &quot;TEXT/JAVASCRIPT&quot; LANGUAGE = JAVASCRIPT>
<!--Hide script from older browsers
function toggleMenu(currMenu){
if(document.all){
thisMenu = eval(&quot;document.all.&quot; + currMenu + &quot;.style&quot;)
if (thisMenu.display == &quot;block&quot;){
thisMenu.display = &quot;none&quot;
}
else{
thisMenu.display = &quot;block&quot;
}
return false
}
else{
return true
}
}
//End hiding script -->
</SCRIPT>


and here is how I'm using it within the html:
<a href=&quot;#null&quot; onClick=&quot;return toggleMenu('summary')&quot;>Site Summary</a>


Can anyone tell me what to do to fix this so that it will work in at least one version of Netscape? Thanks so much.

Jewel
 
Hi Jewel,

I think the problem lies in the <a href=&quot;#null&quot; onClick=&quot;return toggleMenu('summary')&quot;>Site Summary</a>

Try using this instead:
<a href=&quot;#&quot; onClick=&quot;return toggleMenu('summary')&quot;>Site Summary</a>

I think what happens is that when you use #null it will
search for an anchor called null. Maybe that's where the
error is at.

I hope this helps,

BobbaFet Everyone has a right to my opinion.
E-mail me at caswegkamp@hotmail.com
 
Hi BobbaFet,

I tried your suggestion as well as changing it to index.asp so it would call the page again, but I'm still getting the same result. Anymore suggestions?

Thanks,
Jewel
 
I've noticed that Netscape doesn't appear to like some of the IE display modes - if your summary is in a table cell, try display=&quot;table-cell&quot; instead (IE 5 doesn't support this though!)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top