need help with jquery ui accordion -
i have created accordion menu. here js code:
var menu = $('ul.menu', '#sidebar'); menu.accordion({ header: '.parent > a', collapsible: true });
here recreation of have: http://jsfiddle.net/chmpt/
here's delima: want menu collapsed default , can't change html structure because menu produced joomla.
i tried using create method close active menu upon creation of accordion doesn't work right. , here's code:
var menu = $('ul.menu', '#sidebar'); menu.accordion({ create: function(event, ui) { menu.accordion("activate" , false); }, header: '.parent > a', collapsible: true });
any suggestions?
its simple as
menu.accordion({ header:'.parent > a', collapsible: true, active:false });
edit: link jquery ui doc regarding active option
Comments
Post a Comment