Community

When list items in Main menu are set to expanded, is Drupal supposed to print the ".expanded" class on them?

When I set a normal menu block to a region and make the items expanded I get the class ".expanded" printed to the list items. I can grab that and apply some JS.

But when li items in menu menu are set to expanded that class doesn't print to the list items. Is that normal for main menu? Or is something in my theme or templates preventing the class from being applied?

Comments

.expanded or leaf is applied

.expanded or leaf is applied to all menu, AFAIK. Search for function named: yourtheme_menu_link, or yourtheme_menu_link__main_menu to see if $element['#attributes'] is adjusted. The .expanded class is held in $element['#attributes']['class'][]

love, light n laughter

nobody click here