Returns the rendered local tasks at the top level.
function menu_primary_local_tasks() { $links = menu_local_tasks(0); // Do not display single tabs. return count(element_get_visible_children($links['tabs'])) > 1 ? $links['tabs'] : ''; }