Menu

Description:
A jQuery menu plugin. It’s a drop down menu, which behaves like an application menu (click to open, click to close, stays open even after hovering elsewhere). It supports menu creation through HTML markup or through JavaScript. The plugin tries to position its submenus inside the visible area when there is not enough space at the right or bottom border (dimensions plugin required).

Demo and Example page.

This is no stable release! It’s for testing/evaluation purpose only!

Files: (last update: 2007-29-01 - v 0.0.9)

  • jquery.menu.zip (uncompressed, packed and minified source and the demo page)

Required plugins:

License:
The plugin is available under both MIT and GPL licenses (as jQuery itself). This means that you can choose the license that best suits your project, and use it accordingly.

Usage, Examples and available options:
Please take a look at the demo page and the source of the jquery.menu.js file (coming soon).

The plugin was successfully tested on Firefox 2, Opera 9.20 and IE 6/IE 7.

6 Responses to “Menu”

  1. Hmm I haven’t had a chance to look at the new code yet, but how is the performance? I notice that on my site (which I am still trying to get off the ground, lol) the clickmenu plugin (the old stable one) runs kind of slow sometimes. Right now it seems to be running at perfect speed, but there are times I would check it on some people’s computers and it would be a bit laggy. I don’t know if its the way I am implementing it or not. Do you think this new menu plugin would offer better performance (less CPU intensive)?

  2. Well, I’m using the clickmenu excessively in an intranet application. One of the menus has lots of submenus (about 60) and items (more than 300). This one gets _really_ slow, when you are going deep into the menu structure - lets say the fourth or fifth submenu-level. But this is in firefox only and no problem in IE and Opera at all. And it doesn’t seem to be a problem with with the clickmenu plugin but with firefox, as it appears to having problems with firing the mouseover/-out events deep inside a nested unordered list. I’ve tested this with other menu plugins too, with the same result.

    The new plugin is using an own list for each submenu (not nested) which fixes this problem. The problem (on the other hand) is, that the new menu is building its whole HTML markup from scratch, which is taking time. Thus using the new plugin on menus with lots of items can result in slower speed on page load than using the clickmenu plugin.

  3. Thanks for the reply. The later problem you are referring to could simply be done with some sort of caching mechanism, no? I know your dynamically creating it on the client side. perhaps you could create some type of PHP object that you could instantiate and list some parameters to, set caching, then the PHP code would create the JS and everything else that if needed on the server side (and pre-build the HTML menu if need be). Just a suggestion. lol. I could alway try to create this myself as well and pass it back to you if you like it…

  4. That would be cool Daniel, I’d love to see that!

  5. The new click menu works great except that I would like for the menu to automatically close after I have clicked on a menu item. Is there a way I can do this?

  6. sure, just call $.Menu.closeAll(); from your onClick function.

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>
Syntax Highlighting: You can use [js] .. [/js] and [html] .. [/html] for posting code snippets.