function theme_nice_menus_main_menu in Nice Menus 7.2
Same name and namespace in other branches
- 7.3 nice_menus.module \theme_nice_menus_main_menu()
Theme the main menu as a Nice menu.
Return value
mixed An HTML string of Nice main menu links.
File
- ./
nice_menus.module, line 742 - Module to enable CSS dropdown and flyout menus.
Code
function theme_nice_menus_main_menu($variables) {
// Optional. The direction the menu expands. Default is 'down'.
$direction = isset($variables['direction']) ? $variables['direction'] : 'down';
// The number of children levels to display. Use -1 to display all children.
// and use 0 to display no children.
$depth = isset($variables['depth']) ? $variables['depth'] : '-1';
$menu_name = variable_get('menu_main_links_source', 'main-menu');
$output = theme('nice_menus', array(
'id' => 0,
'menu_name' => $menu_name,
'mlid' => 0,
'direction' => $direction,
'depth' => $depth,
));
return $output['content'];
}