When multiple menu items point to the same page, the active trail is selected from the higher-preference menu, even if the item in that menu is disabled.

Consider two menus:

- Nav Page One (node/1)
-- Nav Page Two (node/2) [disabled]
- My Page One (node/1)
-- My Page Two (node/2)

The active trail will show the Navigation menu item (Nav Page One) even though the menu item for node/2 is disabled.

See also:
#1808280: Many menu items for one node results in incorrect menu trail
#1875824: Active trail should favor "non-customized" menu items
#1627276: Active trail system does not respect whether a menu is set as inactive or preferred using menu_set_active_menu_names()

#1 menu-active-trail-disabled-item-1979240-1.patch754 bytesjromine
PASSED: [[SimpleTest]]: [MySQL] 40,341 pass(es). View
Members fund testing for the Drupal project. Drupal Association Learn more


jromine’s picture

Status: Active » Needs review
754 bytes
PASSED: [[SimpleTest]]: [MySQL] 40,341 pass(es). View

Patch attached.

joelpittet’s picture

Issue summary: View changes

@jromine Wondering if this should do what #1875824: Active trail should favor "non-customized" menu items is doing? Where it just sorts the disabled down below?

Also curious if the patch in #1 would disable the feature where disabled item will still allow for it's parent to be triggered active. I think I'd prefer a preferential treatment over exclusion if possible.