function fp_render_menu_block

6.x theme.inc fp_render_menu_block($title = "Tools", $menu_root = "tools", $bool_reset = FALSE)
4.x theme.inc fp_render_menu_block($title = "Tools", $menu_root = "tools")
5.x theme.inc fp_render_menu_block($title = "Tools", $menu_root = "tools")

Render a "menu" block of menu items which are all rooted at the menu_root. So if the menu root is tools, it might return items whose paths look like: tools/fun tools/here/there So long as the menu type is "MENU_TYPE_NORMAL_ITEM". Other types will be ignored.

We want to

4 calls to fp_render_menu_block()
admin_display_main in modules/admin/admin.module
This is the "main" page for the admin module. It's what the user first sees when the click to go to the Admin page.
hook_render_block in modules/blocks/blocks.module
Example of hook_render_block
stats_display_main in modules/stats/stats.module
Main menu screen for this module.
system_render_block in modules/system/system.module

File

includes/theme.inc, line 83

Code

function fp_render_menu_block($title = "Tools", $menu_root = "tools") {
  $rtn = "";

  $is_empty = true;
  if ($title != "") {
    $rtn .= fp_render_curved_line($title);
  }

  $menu_items = menu_get_items_beginning_with($menu_root);

  foreach ($menu_items as $item) {
    if ($item ["type"] != MENU_TYPE_CALLBACK) {
      $rtn .= fp_render_menu_item($item);
      $is_empty = false;
    }
  }

  if ($is_empty) {
    return "";
  }
  //pretty_print($menu_items);

  return $rtn;

}