Entity view (Content)

6 Must Have Menu Modules for Drupal

By hchan
Dec. 2, 2013

In Drupal development, menu items get explicitly linked to node id, rather than aliases. Even though you might specify a menu link to point to /home, the back-end will store it as node/7. If you have a homepage on dev as node/7, but on staging the homepage is node/9, and on prod it's node/19, it can be extremely difficult to move menus across environments. You tested and commit code made on dev, but once deployed to staging, it points to random pages, your /about page goes to your /404 page, and your /home page goes to /faq, while QA wonders if you even look at your own code.

This is an example of one of the issues I encountered while working on menus, albeit a bit exaggerated, and apparently I was only scratching the surface on how menus are created, stored, and exported. Needless to say, I needed a better solution to my “menu problem,” as I quickly saw that I would have to do the same thing many times again in the future. After a bit of iteration, I found a few modules that seemed to help me develop menus, and as such, I have generated a list of a few modules to quickly develop and export menus.

Menu Editor

Menu Editor provides a single page to provide inputs of Title, and Paths. This module helps speed up the creation of menus by allowing users to create menus on one single UI page.

Menu Attributes

By default, Drupal does not allow menus to have attributes such as target or style; luckily, Menu Attributes is a module that allows developers to change attributes of menu links.

Menu Block

If you need to make Menus that need to be separated onto different parts of the page, Menu Block provides configurable blocks of menu trees using Drupal’s standard menu tree navigation. If you need blocks of menu trees at a specific level of a menu, take a look at this module.

Superfish

Superfish integrates the jQuery Superfish plugin with Drupal to provide extra functionality to Drupal’s menus, such as accordions or drop-down menus.

Menu Import

This module helps to easily transfer menus from one Drupal site to another. Menus may contain path alias or node IDs. Another bonus is Drush support.

Export Menu Items (sandbox)

As of this posting, Features does not support two menu items in the same menu that have the same path. This is a sandbox module developed to tackle that issue, by using UUID to identify different menu items, and is fully exportable using Features.

Post Tags: