Click to See Complete Forum and Search --> : Cascade Menu question


Evad Kcetsor
05-08-2003, 12:01 AM
Can someone please tell me how to make the drop down menu disappear once you mouse off? At the moment the only way of making it go away is clicking off somewhere on the page. Can someone help? Thanks in advance.

KeshavaR
05-08-2003, 12:27 AM
Assuming that your menu is made of <DIV>'s and supported with suitable table structure to hold it - you can try the following :

function hide(menuname)
{
eval(menuname+".style.visibility='hidden'");
}

and you can use mouseover property within a cell like this :

<td onmouseover=hide("yourmenu");>Blah Blah</td>


Cheers,

- Keshav

havik
05-08-2003, 12:36 AM
Tricky, depending on how you implemented the menu. So we'd need to see your code to help you.

You could try these menus that have the feature you want:
http://www.dynamicdrive.com/dynamicindex1/sm/index.htm
http://www.dynamicdrive.com/dynamicindex1/topnavbar.htm
http://www.dynamicdrive.com/dynamicindex1/topmen3/index.htm
http://www.dynamicdrive.com/dynamicindex1/topmen4/index.htm

Havik

Evad Kcetsor
05-08-2003, 12:46 AM
Here's the code. Where exactly would I place it?

Thanks havik, I've been looking all over for those! I just may try one of those if the cascade doesn't work.

havik
05-08-2003, 02:56 PM
I looked at the code and it appears that there's no onmouseover, or onmouseout code for the div's. The functions are constantly being called so making this edition will be difficult. I was wondering, before I did anything, is if you are particularily attached to this one cascade menu, or will the others I posted suffice?

(I'm not lazy, just time-smart :D)

Havik

Evad Kcetsor
05-09-2003, 12:49 AM
I'll tell you what, just forget about this cascade one. If you find it difficult to modify, there's no way in hell I could.:D

Thanks for taking the time to look at the code and for the links, really appreciate it.

havik
05-09-2003, 04:10 PM
I could modify this menu but why re-invent the wheel when there's other menus that have that feature :D

Havik