menu_primary_local_tasks

Хочешь помочь с переводом? Это очень просто и быстро. Лишь зарегистрируйся, и можешь тут же начать переводить.

includes/menu.inc, строка 756

Версии
5 – 6
menu_primary_local_tasks()

Возращает оформленные локальные задачи для самого верхнего уровня.

Связанные темы

▾ 2 функции вызывают menu_primary_local_tasks()

phptemplate_menu_local_tasks in themes/garland/template.php
Returns the rendered local tasks. The default implementation renders them as tabs.
theme_menu_local_tasks in includes/menu.inc
Returns the rendered local tasks. The default implementation renders them as tabs.

Код

<?php
function menu_primary_local_tasks() {
  $local_tasks = menu_get_local_tasks();
  $pid = menu_get_active_nontask_item();
  $output = '';

  if (count($local_tasks[$pid]['children'])) {
    foreach ($local_tasks[$pid]['children'] as $mid) {
      $output .= theme('menu_local_task', $mid, menu_in_active_trail($mid), TRUE);
    }
  }

  return $output;
}
?>
Войдите или зарегистрируйтесь, чтобы получить возможность отправлять комментарии

Вход в систему