Menu callback which shows an overview page of all the custom menus and their descriptions.
function menu_overview_page() {
$result = db_query("SELECT * FROM {menu_custom} ORDER BY title", array(), array(
'fetch' => PDO::FETCH_ASSOC,
));
$header = array(
t('Title'),
t('Operations'),
);
$rows = array();
foreach ($result as $menu) {
$row = array();
$row[] = theme('menu_admin_overview', array(
'title' => $menu['title'],
'name' => $menu['menu_name'],
'description' => $menu['description'],
));
$links = array();
$links['list'] = array(
'title' => t('list links'),
'href' => 'admin/structure/menu/manage/' . $menu['menu_name'],
);
$links['edit'] = array(
'title' => t('edit menu'),
'href' => 'admin/structure/menu/manage/' . $menu['menu_name'] . '/edit',
);
$links['add'] = array(
'title' => t('add link'),
'href' => 'admin/structure/menu/manage/' . $menu['menu_name'] . '/add',
);
$row[] = array(
'data' => array(
'#type' => 'operations',
'#links' => $links,
),
);
$rows[] = $row;
}
return theme('table', array(
'header' => $header,
'rows' => $rows,
));
}