Removing ask for password tab

Tue, May 1, 2012 1-minute read

For a Drupal web sites, where adding new user is administrator task, people want to remove create new user, or ask for password tabs from administration menu.

Fortunately Drupal is open and flexible to allow building new modules that will hook with existing menus and alter them (you do not want to mess with core, right :-).

So, just create simple, small module with this code:

* Implementation of hook_menu_alter().
* Remember to clear the menu cache after adding/editing this function.
function mod_askForPass_menu_alter(&$items) {
// Removing certain local navigation tabs that are either undesired 
// or need to be custom relocated.
// Fully unset this tab and his path, don't want it at all. 
// This breaks the path as well:

That is all.