[LON-CAPA-cvs] cvs: loncom /publisher lonunauthorized.pm

bisitz bisitz@source.lon-capa.org
Thu, 14 May 2009 15:36:29 -0000


bisitz		Thu May 14 15:36:29 2009 EDT

  Modified files:              
    /loncom/publisher	lonunauthorized.pm 
  Log:
  - Standard error style for error messages
  - Consistent username:domain output
  
  
Index: loncom/publisher/lonunauthorized.pm
diff -u loncom/publisher/lonunauthorized.pm:1.8 loncom/publisher/lonunauthorized.pm:1.9
--- loncom/publisher/lonunauthorized.pm:1.8	Mon Aug 11 10:18:31 2008
+++ loncom/publisher/lonunauthorized.pm	Thu May 14 15:36:29 2009
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Unauthorized to access construction space
 #
-# $Id: lonunauthorized.pm,v 1.8 2008/08/11 10:18:31 bisitz Exp $
+# $Id: lonunauthorized.pm,v 1.9 2009/05/14 15:36:29 bisitz Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -54,8 +54,11 @@
 # figure out what went wrong
 
     if ($ownerdomain) {
-	$r->print('<h1>'.&mt('Choose another server').'</h1><p>'
+	$r->print('<p class="LC_error">'
                  .&mt('The construction space for this resource is located on another server.')
+                 .'</p>'
+                 .'<p>'
+                 .&mt('Choose another server.')
                  .'</p>');
         my $ownerhome=&Apache::lonnet::homeserver($ownername,$ownerdomain);
         unless ($ownerhome eq 'no_host') {
@@ -65,9 +68,9 @@
                      .'</p>');
         }
     } else {
-        $r->print('<h1>'
+        $r->print('<p class="LC_error">'
                  .&mt('You do not have authoring privileges for this resource')
-                 .'</h1>');
+                 .'</p>');
         my ($realownername)=
 	    ($env{'request.editurl'}=~m{/(?:~|priv/|home/)($LONCAPA::username_re)});
         my $realownerhome=
@@ -75,7 +78,7 @@
 					$r->dir_config('lonDefDomain'));
         unless ($realownerhome eq 'no_host') {
             my $plainname=&Apache::loncommon::plainname($realownername,$r->dir_config('lonDefDomain'));
-            my $user=&mt('[_1] at [_2]',$realownername,$r->dir_config('lonDefDomain'));
+            my $user=$realownername.':'.$r->dir_config('lonDefDomain');
             my $userlink=&Apache::loncommon::aboutmewrapper(
                              $plainname.' ('.$user.')'
                             ,$realownername