Same name and namespace in other branches
  1. 4.7.x modules/help.module \help_menu()
  2. 5.x modules/help/help.module \help_menu()
  3. 6.x modules/help/help.module \help_menu()
  4. 7.x modules/help/help.module \help_menu()

Implementation of hook_menu().

File

modules/help.module, line 11
Manages displaying online help.

Code

function help_menu($may_cache) {
  $items = array();
  if ($may_cache) {
    $items[] = array(
      'path' => 'admin/help',
      'title' => t('help'),
      'callback' => 'help_main',
      'access' => user_access('access administration pages'),
      'weight' => 9,
    );
    foreach (module_list() as $name) {
      if (module_hook($name, 'help')) {
        $items[] = array(
          'path' => 'admin/help/' . $name,
          'title' => t($name),
          'callback' => 'help_page',
          'type' => MENU_CALLBACK,
          'access' => user_access('access administration pages'),
        );
      }
    }
  }
  return $items;
}