function menu_get_names

Build a list of named menus.

Related topics

2 calls to menu_get_names()
MenuRouterTestCase::testMenuGetNames in drupal/modules/simpletest/tests/menu.test
Test menu_get_names().
menu_update_7003 in drupal/modules/menu/menu.install
Add missing custom menus to active menus list.
1 string reference to 'menu_get_names'
MenuRouterTestCase::testMenuGetNames in drupal/modules/simpletest/tests/menu.test
Test menu_get_names().

File

drupal/includes/menu.inc, line 1787
API for the Drupal menu system.

Code

function menu_get_names() {
  $names =& drupal_static(__FUNCTION__);
  if (empty($names)) {
    $names = db_select('menu_links')
      ->distinct()
      ->fields('menu_links', array(
      'menu_name',
    ))
      ->orderBy('menu_name')
      ->execute()
      ->fetchCol();
  }
  return $names;
}