Reply To: Keep menu expanded when different sub-menu option is selected?

Home Forums Older releases 1.0.x Keep menu expanded when different sub-menu option is selected? Reply To: Keep menu expanded when different sub-menu option is selected?

#3195
admin
Keymaster

Hi guys, sorry for this late reply! I’ve, unfortunately, been very busy lately and wasn’t able to look at the forums often..


@straygoat
From what I can see, the menu seems to work as intended (apart from the styling which needs some tweaking):

http://straygoat-technicalauthor.co.uk/smartmenutest/TestingMenuFix/Content/Doors.htm

I guess what bothers you is that when a new page is loaded, the menu is not expanded automatically to show the current selected item. To fix that, you would need to change the following code in “Resources/smartmenus-1.0.0-beta1/initialise-accordion.js”:

				/* Automatically open the accordion to show the current item */
				$('#smartmenu-accordion>ul.sm').smartmenus('itemActivate', $('a.selected'));

to something like this:

				/* Automatically open the accordion to show the current item */
				$('#smartmenu-accordion>ul.sm').smartmenus('itemActivate', $('#smartmenu-accordion>ul.sm a.current'));

Please let me know if that still doesn’t solve the issue.

Register

You will be emailed a link to set your password.

Login

Lost password?