[LON-CAPA-cvs] cvs: loncom /interface domainprefs.pm

albertel lon-capa-cvs-allow@mail.lon-capa.org
Thu, 12 Apr 2007 20:33:31 -0000


albertel		Thu Apr 12 16:33:31 2007 EDT

  Modified files:              
    /loncom/interface	domainprefs.pm 
  Log:
  - adding error css to error messages
  
  
Index: loncom/interface/domainprefs.pm
diff -u loncom/interface/domainprefs.pm:1.10 loncom/interface/domainprefs.pm:1.11
--- loncom/interface/domainprefs.pm:1.10	Tue Apr 10 17:40:12 2007
+++ loncom/interface/domainprefs.pm	Thu Apr 12 16:33:31 2007
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Handler to set domain-wide configuration settings
 #
-# $Id: domainprefs.pm,v 1.10 2007/04/10 21:40:12 albertel Exp $
+# $Id: domainprefs.pm,v 1.11 2007/04/12 20:33:31 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -951,7 +951,8 @@
             $resulttext = &mt('No changes made to log-in page settings');
         }
     } else {
-        $resulttext = &mt('An error occurred: [_1]',$putresult);
+        $resulttext = '<span class="LC_error">'.
+	    &mt('An error occurred: [_1]',$putresult).'</span>';
     }
     if ($errors) {
         $resulttext .= '<br />'.&mt('The following errors occurred: ').'<ul>'.
@@ -993,7 +994,8 @@
             $resulttext = &mt('No changes made to default color schemes');
         }
     } else {
-        $resulttext = &mt('An error occurred: [_1]',$putresult);
+        $resulttext = '<span class="LC_error">'.
+	    &mt('An error occurred: [_1]',$putresult).'</span>';
     }
     if ($errors) {
         $resulttext .= &mt('The following errors occurred: ').'<ul>'.
@@ -1046,7 +1048,7 @@
                                 $confhash->{$role}{$img} = $logourl;
                                 $changes{$role}{$img} = 1;
                             } else {
-                                $error = &mt("Upload of image [_1] for $role page(s) failed because an error occurred publshing the file in RES space. Error was: [_2].",$img,$result);
+                                $error = &mt("Upload of image [_1] for $role page(s) failed because an error occurred publishing the file in RES space. Error was: [_2].",$img,$result);
                             }
                         } else {
                             $error = &mt("Upload of image [_1] for $role page(s) failed because an author role could not be assigned to a Domain Configuation user ([_2]) in domain: [_3].  Error was: [_4].",$img,$confname,$dom,$author_ok);
@@ -1057,7 +1059,7 @@
                 }
                 if ($error) {
                     &Apache::lonnet::logthis($error);
-                    $errors .= '<li>'.$error.'</li>';
+                    $errors .= '<li><span class="LC_error">'.$error.'</span></li>';
                 }
             } elsif ($domconfig->{$role}{$img} ne '') {
                 if ($domconfig->{$role}{$img} !~ m-^(/res/\Q$dom\E/\Q$confname\E/\Q$img\E)/([^/]+)$-) {
@@ -1506,7 +1508,8 @@
             $resulttext = &mt('No changes made to default quotas');
         }
     } else {
-        $resulttext = &mt('An error occurred: [_1]',$putresult);
+        $resulttext = '<span class="LC_error">'.
+	    &mt('An error occurred: [_1]',$putresult).'</span>';
     }
     return $resulttext;
 }
@@ -1570,7 +1573,8 @@
             $resulttext = &mt('No changes made to auto-enrollment settings');
         }
     } else {
-        $resulttext = &mt('An error occurred: [_1]',$putresult);
+        $resulttext = '<span class="LC_error">'.
+	    &mt('An error occurred: [_1]',$putresult).'</span>';
     }
     return $resulttext;
 }
@@ -1689,7 +1693,8 @@
             $resulttext = &mt('No changes made to autoupdates');
         }
     } else {
-        $resulttext = &mt('An error occurred: [_1]',$putresult);
+        $resulttext = '<span class="LC_error">'.
+	    &mt('An error occurred: [_1]',$putresult).'</span>';
     }
     return $resulttext;
 }