open submenu from <a> tag

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
ljp007
Beginner
Beginner
Posts: 2
Joined: Tue Feb 07, 2006 8:21 pm

open submenu from <a> tag

Post by ljp007 »

I dont want to use milonic to generate my main menu, instead, I want to use milonic to open sub menus from the <a> tags in my main menu. For example:


<a href=#" onmouseover="ShowOpenCubeSubMenu">Home</a>


I cant find any samples which illustrate how this is achieved. Any help would be appreciated.

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

Post by John »

Maybe this will help a bit. See http://www.west.asu.edu/sai/. That main menu is all graphics, as defined here...

Code: Select all

with(milonic=new menuname("XPMain")){
style=XPMainStyle;
top = 78;
left = 0;
alwaysvisible = 1;
orientation = "horizontal";
aI("image=/sai/graphics/home.jpg;showmenu=home;url=/sai/;");
aI("image=/sai/graphics/staff.jpg;showmenu=staff;");
aI("image=/sai/graphics/tech.jpg;showmenu=tech;");
aI("image=/sai/graphics/new.jpg;showmenu=new;");
aI("image=/sai/graphics/edit.jpg;showmenu=edit;");
aI("image=/sai/graphics/services.jpg;showmenu=services;");
aI("image=/sai/graphics/about.jpg;showmenu=about;");
}
Hover over a graphic and the sub-menu drops, as generated by Milonic. I suspect you could replace the showmenu= with a URL.

Short on time right now. Sorry. Let us know if that helps.
John
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Post by Ruth »

Hi,

Are you saying you want the submenu to open from a link in your menu? That's done with the showmenu when you mouseover the item. If you mean you want the submenus to open from a link on your page then you want sample 24 which is opening menus using the pop function.

http://milonic.com/menusample24.php

You can also see methods and functions for explanations of the popup and popdown and how to use them. It's at the bottom of the page.

http://milonic.com/menu_methods.php

Ruth
Post Reply