--- loncom/interface/lonmenu.pm 2008/12/08 23:07:03 1.248 +++ loncom/interface/lonmenu.pm 2009/02/13 20:20:30 1.252 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Routines to control the menu # -# $Id: lonmenu.pm,v 1.248 2008/12/08 23:07:03 raeburn Exp $ +# $Id: lonmenu.pm,v 1.252 2009/02/13 20:20:30 schafran Exp $ # # Copyright Michigan State University Board of Trustees # @@ -207,7 +207,7 @@ sub menubuttons { my $logo=&Apache::loncommon::lonhttpdurl("/adm/lonIcons/minilogo.gif"); $logo = 'LON-CAPA Logo'; + $logo.'" alt="LON-CAPA Logo" class="LC_noBorder" />'; if ($env{'request.state'} eq 'construct') { if (($env{'request.noversionuri'} eq '') || (!defined($env{'request.noversionuri'}))) { @@ -1027,7 +1027,7 @@ sub switch { my $pic= ''.$text.''; + '" align="'.($nobreak==3?'right':'left').'" class="LC_noBorder" />'; if ($env{'browser.interface'} eq 'faketextual') { # Accessibility if ($nobreak==3) { @@ -1094,8 +1094,8 @@ sub inlinemenu { foreach my $cat (keys(%category_members)) { if ($category_positions{$cat} ne "$col,$row") { next; } #$output.=''; - $output.='
'; - $output.='

'.&mt($category_names{$cat}).'

'; + $output.='
'; + $output.='

'.&mt($category_names{$cat}).'

'; $output.='
'.&mt($category_names{$cat}).'
'; my %active=(); foreach my $menu_item (split(/\:/,$category_members{$cat})) { @@ -1227,8 +1227,23 @@ sub rawconfig { } elsif ($pro eq 'tools') { my @tools = ('aboutme','blog','portfolio'); if (grep(/^\Q$prt\E$/,@tools)) { - if (defined($env{'environment.tools.'.$prt}) && - ($env{'environment.tools.'.$prt} == 0)) { + if (!&Apache::lonnet::usertools_access($env{'user.name'}, + $env{'user.domain'}, + $prt,undef,'tools')) { + $output.=&clear($row,$col); + next; + } + } elsif ($prt eq 'reqcrs') { + my $showreqcrs = 0; + foreach my $type ('official','unofficial') { + if (&Apache::lonnet::usertools_access($env{'user.name'}, + $env{'user.domain'}, + $type,undef,'requestcourses')) { + $showreqcrs = 1; + last; + } + } + if (!$showreqcrs) { $output.=&clear($row,$col); next; } @@ -1459,7 +1474,7 @@ function set_bookmark() { +"type='text' name='title' size=45 value='"+clienttitle+"' />" +"
Address:

<\\/center><\\/td>" +"<\\/tr><\\/table><\\/form><\\/center>" +'$end_page_bookmark' );