--- loncom/interface/lonmenu.pm 2013/11/24 15:32:39 1.422 +++ loncom/interface/lonmenu.pm 2014/01/06 15:05:50 1.425 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Routines to control the menu # -# $Id: lonmenu.pm,v 1.422 2013/11/24 15:32:39 raeburn Exp $ +# $Id: lonmenu.pm,v 1.425 2014/01/06 15:05:50 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -283,8 +283,14 @@ sub primary_menu { $menu{$position} .= prep_menuitem($menuitem); } } - return ("
    $menu{'left'}
", - "
    $menu{'right'}
"); + my @output = ('',''); + if ($menu{'left'} ne '') { + $output[0] = "
    $menu{'left'}
"; + } + if ($menu{'right'} ne '') { + $output[1] = "
    $menu{'right'}
"; + } + return @output; } #returns hashref {user=>'',dom=>''} containing: @@ -508,8 +514,11 @@ sub create_submenu { if ($count == $numsub) { $borderbot = 'border-bottom:1px solid black;'; } + if ($href ne '') { + $target = ' target="_top"'; + } $menu .= '
  • '; + $borderbot.'">'; if ($translate) { $menu .= &mt($item->[1]); } else { @@ -1381,7 +1390,7 @@ sub rawconfig { sub check_for_rcrs { my $showreqcrs = 0; - my @reqtypes = ('official','unofficial','community'); + my @reqtypes = ('official','unofficial','community','textbook'); foreach my $type (@reqtypes) { if (&Apache::lonnet::usertools_access($env{'user.name'}, $env{'user.domain'},