Main menu open onclick?

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
stevvi
Advanced
Advanced
Posts: 23
Joined: Mon Oct 20, 2003 7:09 pm

Main menu open onclick?

Post by stevvi »

Hi,

I'm sure this is a simple problem and i'm being totally stupid, but how do I get a main menu to show the submenus onclick rather than onmouseover? I've tried using "openonclick" just about anywhere and everywhere but have had no luck.

Concise advice would be greatly appreciated.

Thanx.
User avatar
fredlongworthhighschool
Mega Advanced
Mega Advanced
Posts: 362
Joined: Fri Jun 27, 2003 11:34 am
Location: Manchester, England.
Contact:

Post by fredlongworthhighschool »

Hmmm, doesn't work for me either.
Andy Davis
Web Designer & Smartboard Manager

Fred Longworth High School, Manchester, England.
User avatar
Hergio
Milonic God
Milonic God
Posts: 1123
Joined: Wed Jun 12, 2002 7:46 pm
Location: Rochester, NY

Post by Hergio »

Are you doing it exactly as the example shows it on the sample pages? What RC of the menu are you using? What browser are you using? Got a URL? Give us somethin to chew on! hehe :lol:
Dave Hergert
Software Engineer
"Helping to make the menu better, one :?: at a time."
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 stevvi,

openonclick is a menu item property, so it must be defined for each individual menu item that you want it to affect. So, for example, if a menu item -- defined with aI() -- uses the showmenu property to open a submenu, but you don't want the submenu to open unless the user clicks the menu item, you would add openonclick=1 to that item's aI() line. Like so:

Code: Select all

aI("text=Item Text;showmenu=Submenu Name;openonclick=1;");
That way, the user must click on the item named "Item Text" to open the submenu named "Submenu Name". openonclick=true should also work.

Hope that helps,

Kevin
User avatar
Hergio
Milonic God
Milonic God
Posts: 1123
Joined: Wed Jun 12, 2002 7:46 pm
Location: Rochester, NY

Post by Hergio »

Stevvi, were you able to get this working? If tou did as Kevin said and it worked, let us know. If not, throw us a URL so we can take a look.
Dave Hergert
Software Engineer
"Helping to make the menu better, one :?: at a time."
User avatar
nbarth
Super Advanced
Super Advanced
Posts: 41
Joined: Tue Jul 29, 2003 11:03 am
Location: Minnesota
Contact:

RC18 doesn't work for me either

Post by nbarth »

Stevi and Hergio,

I am using RC18 and it is not working for me, as well. Could this be a bug? I have tried it as a menu item option and as a straight menu option using both "openonclick=1;" and "openonclick=true;", neither one worked.

Let me know if you figure it out, and I will do the same.

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

Post by John »

Works fine for me, guys - RC18...

Code: Select all

	aI("text=Diversions;showmenu=diversions;image=/sai/graphics/xpblank.gif;status=Diversions;openonclick=1;");
John
User avatar
nbarth
Super Advanced
Super Advanced
Posts: 41
Joined: Tue Jul 29, 2003 11:03 am
Location: Minnesota
Contact:

Got it

Post by nbarth »

Ok,

I've been able to get it to work. I was using the wrong menu.js file. :? Sorry. However, in version 3, if you clicked on one menu you could mouse over another menu and that menu would open it's submenu even if it also had the onclick option set. Is the change on purpose or is this something that should not happen? I did like the fact that, in version 3, you could click one menu and browse until you made a selection, and if you moved the mouse off the menu it would close and you would be reqired to click again. In version 5 it requires you to click on each menu individually.

Nicholas
User avatar
kevin3442
Milonic God
Milonic God
Posts: 2460
Joined: Sat Sep 07, 2002 12:09 am
Location: Lincoln, NE
Contact:

Re: Got it

Post by kevin3442 »

nbarth wrote:...I did like the fact that, in version 3, you could click one menu and browse until you made a selection, and if you moved the mouse off the menu it would close and you would be reqired to click again. In version 5 it requires you to click on each menu individually.
An excellent point Nicholas. In other words, when a click was required in v3, the menu acted more like a standard application menu bar (at least a Windows app), allowing the user to click on one main menu item, then browse through the other menus by simply pointing at other main menu items. In v5, since it's an item property, the user has to click on each item to open the submenu it calls. I would also like the v3 approach, or at least the option of it.

Perhaps there could be two openonclick properties: one would be a menu property and one would be a menu item property (like the current one). There are examples of this with other properties already. The onenonclick menu property would affect the entire menu, causing it to behave the way Nicholas descibed for v3. The openonclick menu item property would behave as it does now, and would override the menu property.

Thoughts?

Kevin
Post Reply