4.6.x menu.inc theme_menu_tree($pid = 1)
4.7.x menu.inc theme_menu_tree($pid = 1)
5.x menu.inc theme_menu_tree($pid = 1)
6.x menu.inc theme_menu_tree($tree)
7.x menu.inc theme_menu_tree($variables)

Generate the HTML for a menu tree.

Parameters

$pid: The parent id of the menu.

Related topics

3 theme calls to theme_menu_tree()
menu_block in modules/menu/menu.module
Implementation of hook_block().
menu_tree in includes/menu.inc
Returns a rendered menu tree.
user_block in modules/user/user.module
Implementation of hook_block().

File

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

Code

function theme_menu_tree($pid = 1) {
  if ($tree = menu_tree($pid)) {
    return "\n<ul class=\"menu\">\n" . $tree . "\n</ul>\n";
  }
}