By mysocom on
I have menu code that results in two main tabs and two subtabs under the default local task. Where is menu link ? I expected http://site/milkshake
I don't have any items of milkshake in my menu.
function milkshake_menu($may_cache) {
$items = array();
if (!$may_cache) {
$items[] = array(
'path' => 'milkshake',
'title' => t('Milkshake flavors'),
'callback' => 'milkshake_overview',
'type' => MENU_CALLBACK
);
$items[] = array(
'path' => 'milkshake/list',
'title' => t('List flavors'),
'type' => MENU_DEFAULT_LOCAL_TASK,
'access' => user_access('list flavors'),
'weight' => 0
);
$items[] = array(
'path' => 'milkshake/add',
'title' => t('Add flavor'),
'callback' => 'milkshake_add',
'type' => MENU_LOCAL_TASK,
'access' => user_access('add flavor'),
'weight' => 1
);
$items[] = array(
'path' => 'milkshake/list/fruity',
'title' => t('Fruity flavors'),
'callback' => 'milkshake_list',
'type' => MENU_LOCAL_TASK,
'access' => user_access('list flavors'),
);
$items[] = array(
'path' => 'milkshake/list/candy',
'title' => t('Candy flavors'),
'callback' => 'milkshake_list',
'type' => MENU_LOCAL_TASK,
'access' => user_access('list flavors'),
);
}
return $items;
}
Sorry for this simple question.