--- loncom/auth/lonroles.pm 2010/07/30 20:35:16 1.255
+++ loncom/auth/lonroles.pm 2010/08/12 23:40:49 1.256.2.1
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# User Roles Screen
#
-# $Id: lonroles.pm,v 1.255 2010/07/30 20:35:16 raeburn Exp $
+# $Id: lonroles.pm,v 1.256.2.1 2010/08/12 23:40:49 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -57,7 +57,8 @@ course they should act on, etc. Both in
handler determines via C $msg ');
- if ($switchwarning) {
- $r->print($switchwarning.' ');
+ if ($switchwarning) {
+ $r->print($switchwarning.'
');
- if (&Apache::loncommon::show_course()) {
- $r->print(&mt('Display courses'));
- } else {
- $r->print(&mt('Display roles'));
+ if ($switchwarning ne '' || $switchserver ne '') {
+ &Apache::loncommon::content_type($r,'text/html');
+ &Apache::loncommon::no_cache($r);
+ $r->send_http_header;
+ my $end_page=&Apache::loncommon::end_page();
+ $r->print(&Apache::loncommon::start_page('Selected course unavailable on this server').
+ '
');
+ if (&Apache::loncommon::show_course()) {
+ $r->print(&mt('Display courses'));
+ } else {
+ $r->print(&mt('Display roles'));
+ }
+ $r->print('');
+ } elsif ($switchserver) {
+ $r->print(&mt('This course requires a newer version of LON-CAPA than is installed on this server.').
+ '
'.
+ ''.
+ &mt('Switch Server').
+ '');
}
- $r->print('
'.
- ''.
- &mt('Switch Server').
- '');
+ $r->print('