Milonic provide full featured pull down web menus for some of the worlds largest companies
click here to see what it can do for you

Download Milonic DHTML Menu
Buy Milonic DHTML Menu

Back To Start Of Archive
Taken From The Forum: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:28

Hidding a menu


Poster: gporterfield
Dated: Sunday June 15 2003 - 22:59:29 BST

I am working on a new site design. Part of my concept includes the need to hide the menu (visible = false) at some times. (Don't ask why.) Of course, I will "unhide" the menu later on.

I've tried a few variations of "menu0.visible = false;" but no success. Any suggestions on how to achieve this? :?:

TIA,
George


Poster: Andy
Dated: Monday June 16 2003 - 23:43:35 BST

try this

mn=getMenuByName("menuname")
menuobject=gmobj("menu"+mn)
menuobject.style.visibility="hidden"

Change "hidden" to "visible" to show it again

Cheers
Andy

ps: This should work in verson 3 and version 4

Hidding a menu


Poster: gporterfield
Dated: Wednesday June 18 2003 - 0:26:56 BST

Thanks Andy.

Your suggetion works great in IE, but NS4 complains:
menuobject.style has no properties.

Now I should be able to figure out the syntax difference for NS4, but it is escaping me right now.

TIA,
George


Poster: Andy
Dated: Wednesday June 18 2003 - 7:38:07 BST

Oh yeah, forgot about him

Try this

mn=getMenuByName("menuname")
menuobject=gmobj("menu"+mn)
if("ns4)
{
menuobject.visibility="hide"
}
else
{
menuobject.style.visibility="hidden"
}


Cheers
Andy

Hidding a menu


Poster: gporterfield
Dated: Thursday June 19 2003 - 1:38:05 BST

Thanks Andy. Should have been able to figure out that syntax myself, but yesterday was not a good day for thinking.

:D

After "un"hidding, how to make "alwayvisible&


Poster: gporterfield
Dated: Sunday July 6 2003 - 23:04:02 BST

OK, in much the same manner, is also possible to change the value of the "alwaysvisible" attribute?


Poster: Hergio
Dated: Friday July 11 2003 - 2:41:01 BST

I found a flag for each menu that is set when its declared as alwaysvisible. I was able to edit it dynamically (programmaticaly) but it began giving me errors. There seems to be more to it than just the menu[8] flag. (i think that was where i found it)