You are here

function og_menu_single_block_view in OG Menu Single 7

Implements hook_block_view().

File

./og_menu_single.module, line 370
Creates a single menu per organic group on a site.

Code

function og_menu_single_block_view($delta = '') {
  $block = array();
  if ($plid = og_menu_single_get_active_plid()) {
    $tree = og_menu_single_children_items($plid, variable_get('og_menu_single_block_menu_depth', MENU_MAX_DEPTH));
    if ($tree && ($output = menu_tree_output($tree))) {
      $block['content'] = $output;
    }
  }
  return $block;
}