Is it possible to add a class such as “Selected” to an
Here is the code I am using to trigger the menu and add the class…
$(document).ready(function () {
$("#jobs-search").click(function() {
$('#menu-left li#search-jobs').addClass('Selected');
$("#menu-left").trigger("open.mm");
});
});
The function adds the class, but it does not open the submenu like I want it to. Is this possible?
just put the class "mm-opened" to the list item you want to expand. you can add the class after the mmenu is initialised. the submenu opens automatically - no need to refresh ;)