menu_tree_data

Definition

menu_tree_data($result = NULL, $parents = array(), $depth = 1)
drupal/includes/menu.inc, line 1086

Description

Build the data representing a menu tree.

Parameters

$result The database result.

$parents An array of the plid values that represent the path from the current page to the root of the menu tree.

$depth The depth of the current menu tree.

Return value

See menu_tree_page_data for a description of the data structure.

Related topics

Namesort iconDescription
Menu systemDefine the navigation menus, and route page requests to code based on URLs.

Code

function menu_tree_data($result = NULL, $parents = array(), $depth = 1) {
  list(, $tree) = _menu_tree_data($result, $parents, $depth);
  return $tree;
}