function theme_menu_block_item in Menu Block 5.2
Same name and namespace in other branches
- 5 menu_block.module \theme_menu_block_item()
Generate the HTML output for a menu item and submenu.
1 theme call to theme_menu_block_item()
- menu_block_tree in ./
menu_block.module - Returns a rendered menu tree or menu list.
File
- ./
menu_block.module, line 262 - Provides configurable blocks of menu items.
Code
function theme_menu_block_item($link, $has_children, $menu = '', $in_active_trail = FALSE, $extra_class = NULL) {
$class = $menu ? 'expanded' : ($has_children ? 'collapsed' : 'leaf');
if (!empty($extra_class)) {
$class .= ' ' . $extra_class;
}
if ($in_active_trail) {
$class .= ' active-trail';
}
return '<li class="' . $class . '">' . $link . $menu . "</li>";
}