You are here

function menu_primary_local_tasks in Drupal 7

Same name and namespace in other branches
  1. 8 core/includes/menu.inc \menu_primary_local_tasks()
  2. 4 includes/menu.inc \menu_primary_local_tasks()
  3. 5 includes/menu.inc \menu_primary_local_tasks()
  4. 6 includes/menu.inc \menu_primary_local_tasks()

Returns the rendered local tasks at the top level.

Related topics

2 calls to menu_primary_local_tasks()
menu_local_tabs in includes/menu.inc
Returns a renderable element for the primary and secondary tabs.
template_preprocess_overlay in modules/overlay/overlay.module
Implements template_preprocess_HOOK() for overlay.tpl.php

File

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

Code

function menu_primary_local_tasks() {
  $links = menu_local_tasks(0);

  // Do not display single tabs.
  return $links['tabs']['count'] > 1 ? $links['tabs']['output'] : '';
}