--- loncom/auth/lonlogin.pm 2008/10/02 11:28:49 1.106 +++ loncom/auth/lonlogin.pm 2009/08/12 19:52:15 1.106.4.3 @@ -1,7 +1,7 @@ # The LearningOnline Network # Login Screen # -# $Id: lonlogin.pm,v 1.106 2008/10/02 11:28:49 bisitz Exp $ +# $Id: lonlogin.pm,v 1.106.4.3 2009/08/12 19:52:15 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -46,7 +46,7 @@ sub handler { (join('&',$ENV{'QUERY_STRING'},$env{'request.querystring'}, $ENV{'REDIRECT_QUERY_STRING'}), ['interface','username','domain','firsturl','localpath','localres', - 'token']); + 'token','role','symb']); if (!defined($env{'form.firsturl'})) { &Apache::lonacc::get_posted_cgi($r,['firsturl']); } @@ -84,7 +84,7 @@ sub handler { $r->print( $start_page .'
'.&mt('Please either [_1]continue the current session[_2] or [_3]logout[_4].', + .'
'.&mt('Please either [_1]continue the current session[_2] or [_3]log out[_4].', '','','','').'
' .'' .$end_page @@ -179,8 +179,18 @@ sub handler { if ($uextkey>2147483647) { $uextkey-=4294967296; } # -------------------------------------------------------- Store away log token + my $tokenextras; + if ($env{'form.role'}) { + $tokenextras = '&role='.&escape($env{'form.role'}); + } + if ($env{'form.symb'}) { + if (!$tokenextras) { + $tokenextras = '&'; + } + $tokenextras .= '&symb='.&escape($env{'form.symb'}); + } my $logtoken=Apache::lonnet::reply( - 'tmpput:'.$ukey.$lkey.'&'.$firsturl, + 'tmpput:'.$ukey.$lkey.'&'.$firsturl.$tokenextras, $lonhost); # ------------------- If we cannot talk to ourselves, we are in serious trouble @@ -266,6 +276,14 @@ sub handler { if ($login eq '') { $login = $iconpath.'/'.&mt('userauthentication.gif'); } + my $showbanner = 1; + my $showmainlogo = 1; + if (defined(&Apache::loncommon::designparm('login.showlogo_img',$domain))) { + $showbanner = &Apache::loncommon::designparm('login.showlogo_img',$domain); + } + if (defined(&Apache::loncommon::designparm('login.showlogo_logo',$domain))) { + $showmainlogo = &Apache::loncommon::designparm('login.showlogo_logo',$domain); + } my $showadminmail=&Apache::loncommon::designparm('login.adminmail',$domain); my $showcoursecat = &Apache::loncommon::designparm('login.coursecatalog',$domain); @@ -275,7 +293,8 @@ sub handler { my $now=time; my $js = (<
+HEADER
+ if ($showbanner) {
+ $r->print(< |
+ENDSTART
+ if ($showmainlogo) {
+ $r->print(<
ENDTOP
-} else {
- $r->print(' | ';
$r->print(<The LearningOnline Network with CAPA' - .''.&mt('Text-based Interface Login').'' - .$announcements); -} - $r->print('
|