Menus that active submenus on a different area of page

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
dstewart21
Beginner
Beginner
Posts: 5
Joined: Thu May 15, 2003 3:44 pm

Menus that active submenus on a different area of page

Post by dstewart21 »

Look at http://www.hotelroanoke.com

See how the submenu disappears when you mouseout? Is there a way to alleviate this behavior so that the submenus remain intact?
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Post by Ruth »

How and in particular why would you want to do that? When I go to the page no submenu is visible, so for example, when I mouseover Accomodations the submenu for that opens just above the picture, and of course when i mouse out to another submenu the first disappears and the second appears, if the first remained always visible then the next menu I moused over would open and be on top of it and the text of the two would be mixed together. So, perhaps I'm not understanding what it is you want to do with the menu. Could you be a little more detailed in what you want the menu to do and look like on the page.

Ruth
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Post by John »

I'm confused as well. Are those actually submenus that pop, and are they supposed to be active? Whenever I try to get to one it closes as soon as I move off the main menu.
John
dstewart21
Beginner
Beginner
Posts: 5
Joined: Thu May 15, 2003 3:44 pm

Post by dstewart21 »

John wrote:I'm confused as well. Are those actually submenus that pop, and are they supposed to be active? Whenever I try to get to one it closes as soon as I move off the main menu.
That's what I'm trying to avoid. I want the submenu to stay visible so I can move the mouse up to click on it. Does this make sense?
User avatar
kevin3442
Milonic God
Milonic God
Posts: 2460
Joined: Sat Sep 07, 2002 12:09 am
Location: Lincoln, NE
Contact:

Post by kevin3442 »

Hi dstewart21,

I hate to tell you this, but the menus on your page are not Milonic Menus. Milonic code is not used anywhere on the page you gave. The menus you have so far are DIVs, each containing a different submenu image. The divs start out hidden and are shownas you mouse over a main menu selection, then hidden again when you mouse out. The function that does this is ShowHide(), in your dhtml.js file. Judging by the other function in that file (MM_findObj()), I'd say these functions were generated automatically by DreamWeaver (MM_ seems to be a common prefix in DreamWeaver functions, although I've never know why "MM"). Anyway... you could do what you want with a Milonic Menu, using the menu's keepalive property, but you aren't using Milonic Menus right now.

The root of the problem in your setup is that the ShowHide() function is called to show the div when you mouse over a main menu item, then called again to hide the div when you mouse out of the same main menu item (using the items onmousover and onmouoseout events). If you're going to stick with this DreamWeaver method, it might be a better approach to write a wrapper js function that you pass the name of the div (submenu) to open, then it will in turn call ShowHide() to close any previously opened div and open the one you want. That way, the last one you opened will remain open until you open a different one.

Good Luck,

Kevin
dstewart21
Beginner
Beginner
Posts: 5
Joined: Thu May 15, 2003 3:44 pm

Post by dstewart21 »

My apologies, I should've clarified further. I was inquiring to see if the Milonic menu script could be modified to work in the same fashion as that site (without the submenu disappearing).
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Post by Ruth »

YEs, if I understand what you want it can be set to allow that using the keepalive function.

Ruth
User avatar
John
 Team
 Team
Posts: 5967
Joined: Sun May 19, 2002 8:23 pm
Location: Phoenix, AZ
Contact:

Post by John »

The only thing we're a little stumped on right now is the line that snakes up from the menu to the subs. We'll probably figure it out, but it might take some time.

Other than that, Ruth is, of course, correct. We can do that.
John
Post Reply