From: moodler Date: Fri, 22 Nov 2002 17:27:56 +0000 (+0000) Subject: ALL LANGUAGE EDITORS PLEASE NOTICE THIS CHECKIN X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=7f1717c61e41147fc4ed5a4025315d71a1e982e7;p=moodle.git ALL LANGUAGE EDITORS PLEASE NOTICE THIS CHECKIN I've changed htmlentities to htmlspecialchars in this file, to fix bugs with editing multibyte languages (ie Japanese). Please be cautious and let me know if this causes any problems when editing your language (it shouldn't, but I don't want to spoil your day!) --- diff --git a/admin/lang.php b/admin/lang.php index 8c10772177..e2626056b1 100644 --- a/admin/lang.php +++ b/admin/lang.php @@ -87,7 +87,7 @@ $first = true; foreach ($enstring as $key => $value) { if (!isset($string[$key])) { - $value = htmlentities($value); + $value = htmlspecialchars($value); $value = str_replace("$"."a", "\\$"."a", $value); if ($first) { echo "

".get_string("stringsnotset","","$langdir/$file")."

";
@@ -179,7 +179,7 @@
             }
             echo "";
             foreach ($enstring as $key => $envalue) {
-                $envalue = nl2br(htmlentities($envalue));
+                $envalue = nl2br(htmlspecialchars($envalue));
                 $envalue = str_replace("\$a","\$a", $envalue);  // Make variables bold
                 // TODO:  It would be nice if all the $a->something variables were bold too
 
@@ -188,7 +188,7 @@
                 echo "";
 
                 $value = str_replace("\\","",$string[$key]);          // Delete all slashes
-                $value = htmlentities($value);
+                $value = htmlspecialchars($value);
                 if ($editable) {
                     echo "
cellheading\" VALIGN=TOP>$envalue"; if (isset($string[$key])) {