You are here

function admin_menu_footer in Administration menu 6

Same name and namespace in other branches
  1. 5.3 admin_menu.module \admin_menu_footer()
  2. 5 admin_menu.module \admin_menu_footer()
  3. 5.2 admin_menu.module \admin_menu_footer()
  4. 6.3 admin_menu.module \admin_menu_footer()

Implementation of hook_footer().

Admin menu was previously output via hook_block(), but suffered from theme-specific stylesheets that may be applied to layout blocks. We now output Admin menu in the footer to circumvent this.

File

./admin_menu.module, line 129
Renders a menu tree for administrative purposes as a dropdown menu at the top of the window.

Code

function admin_menu_footer($main = 0) {
  if (!user_access('access administration menu') || admin_menu_suppress(FALSE)) {
    return;
  }
  $content = '<div id="admin-menu">';
  $content .= admin_menu_tree_output(menu_tree_all_data('admin_menu'));
  $content .= '</div>';
  return $content;
}