Same name and namespace in other branches其他分支中的同名和命名空间相同

Alter the data being saved to the {menu_router} table after hook_menu is invoked.更改在调用 hook_menu 后保存到 {menu_router} 表的数据。

This hook is invoked by menu_router_build                                    (). The menu definitions are passed in by reference. Each element of the $items array is one item returned by a module from hook_menu. Additional items may be added, or existing items altered.此钩子由 menu_router_build() 调用。菜单定义通过引用传递。$items数组的每个元素都是模块从hook_menu返回的项。可以添加其他项目,或更改现有项目。

Parameters 参数 

$items: Associative array of menu router definitions returned from hook_menu().

Related topics 相关主题 

1 function implements hook_menu_alter()1 函数实现 hook_menu_alter()

  •                                            

1 invocation of hook_menu_alter()1 次调用 hook_menu_alter()

File 文件 


                               

  • modules/system/

    system.api.php                                        

    , line 1292模块/系统/system.api.php,第 1292 行
  • Hooks provided by Drupal core and the System module.Drupal 核心和系统模块提供的钩子。


                               

Code 法典 

function hook_menu_alter(&$items) {

  // Example - disable the page at node/add
  $items['node/add']['access callback'] = FALSE;
}