]> git.mjollnir.org Git - moodle.git/commitdiff
Whoops, forgot part of the optimisation.
authormoodler <moodler>
Tue, 27 Apr 2004 13:58:54 +0000 (13:58 +0000)
committermoodler <moodler>
Tue, 27 Apr 2004 13:58:54 +0000 (13:58 +0000)
lib/weblib.php

index b0ced0c45a2b46c377e58fbbf1ea5444a66f2d8d..8cb41db88c25a111443b7d4571f22f84e8144b49 100644 (file)
@@ -931,13 +931,13 @@ function print_header ($title="", $heading="", $navigation="", $focus="", $meta=
     // Add a stylesheet for the HTML editor
     $meta = "<style type=\"text/css\">@import url($CFG->wwwroot/lib/editor/htmlarea.css);</style>\n$meta\n";
 
-    // Character set could be optimised by carrying the charset variable around in $USER
     if (!empty($CFG->unicode)) {
         $encoding = "utf-8";
     } else if (!empty($SESSION->encoding)) {
         $encoding = $SESSION->encoding;
     } else {
         $encoding = get_string("thischarset");
+        $SESSION->encoding = $encoding;
     }
     $meta = "<meta http-equiv=\"content-type\" content=\"text/html; charset=$encoding\" />\n$meta\n";