Close a menu tab once I open anotherone
-
I need to find a way to manipulate the menu items so that when I open a menu item, if another one is open, it should close. I’m accessing the items like this:
var $navlinks = $('#navigation-bar .site-menu #quadmenu .quadmenu-item.quadmenu-item-object-mega.quadmenu-item-has-children .quadmenu-dropdown-toggle');
I wanted to add a click event with a simple control that should remove the ‘.open’ class if another one has it. The problem is that any element of that div where I have nested my menu items does not “listen” to my click. I couldn’t find any information on the docs about this matter, and it’s weird because it seems like a very basic feature, so I’m sure I’m doing something wrong.
Thanks in advance for the help!
(please note that im using the quadmenu page as an example because I cant share my project)The page I need help with: [log in to see the link]
- The topic ‘Close a menu tab once I open anotherone’ is closed to new replies.