[LON-CAPA-cvs] cvs: loncom(version_2_9_X) /auth lonlogin.pm

raeburn raeburn@source.lon-capa.org
Tue, 09 Feb 2010 17:46:45 -0000


raeburn		Tue Feb  9 17:46:45 2010 EDT

  Modified files:              (Branch: version_2_9_X)
    /loncom/auth	lonlogin.pm 
  Log:
  - Backport 1.125.
  
  
Index: loncom/auth/lonlogin.pm
diff -u loncom/auth/lonlogin.pm:1.106.4.3 loncom/auth/lonlogin.pm:1.106.4.4
--- loncom/auth/lonlogin.pm:1.106.4.3	Wed Aug 12 19:52:15 2009
+++ loncom/auth/lonlogin.pm	Tue Feb  9 17:46:44 2010
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Login Screen
 #
-# $Id: lonlogin.pm,v 1.106.4.3 2009/08/12 19:52:15 raeburn Exp $
+# $Id: lonlogin.pm,v 1.106.4.4 2010/02/09 17:46:44 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -81,11 +81,15 @@
 	    &Apache::loncommon::start_page('Already logged in');
 	my $end_page = 
 	    &Apache::loncommon::end_page();
+        my $dest = '/adm/roles';
+        if ($env{'form.firsturl'} ne '') {
+            $dest = $env{'form.firsturl'};
+        }
 	$r->print(
                   $start_page
                  .'<h1>'.&mt('You are already logged in!').'</h1>'
                  .'<p>'.&mt('Please either [_1]continue the current session[_2] or [_3]log out[_4].',
-                  '<a href="/adm/roles">','</a>','<a href="/adm/logout">','</a>').'</p>'
+                  '<a href="'.$dest.'">','</a>','<a href="/adm/logout">','</a>').'</p>'
                  .'<p><a href="/adm/loginproblems.html">'.&mt('Login problems?').'</a></p>'
                  .$end_page
                  );