]> git.mjollnir.org Git - moodle.git/commitdiff
PostgreSQL 8 compatibility fix for database character set detecting
authorpatrickslee <patrickslee>
Sun, 23 Apr 2006 23:39:56 +0000 (23:39 +0000)
committerpatrickslee <patrickslee>
Sun, 23 Apr 2006 23:39:56 +0000 (23:39 +0000)
install.php
lib/setuplib.php

index ff3c6817b080ad26f26a934d8fcc488939f22d91..72f7990997460c70679e89e1ccf1700a06677874 100644 (file)
@@ -329,7 +329,7 @@ if ($INSTALL['stage'] == DATABASE) {
                         $rs = $db->Execute("SHOW server_encoding");
                         if ($rs && $rs->RecordCount() > 0) {
                             $encoding = $rs->fields['server_encoding'];
-                            if (strtoupper($encoding) != 'UNICODE') {
+                            if (strtoupper($encoding) != 'UNICODE' || strtoupper($encoding) != 'UTF8') {
                                 $errormsg = get_string('dbwrongencoding', 'install', $encoding);
                                 $nextstage = DATABASE;
                                 $INSTALL['showskipdbencodingtest'] = true;
index 53355f2cefad306d014cd83655574e7666554564..f0bfc1d56acf4db66a2022c736f33c4c57e28f9f 100644 (file)
@@ -108,7 +108,7 @@ function setup_is_unicodedb() {
             $rs = $db->Execute("SHOW server_encoding");
             if ($rs && $rs->RecordCount() > 0) {
                 $encoding = $rs->fields['server_encoding'];
-                if (strtoupper($encoding) == 'UNICODE') {
+                if (strtoupper($encoding) == 'UNICODE' || strtoupper($encoding) == 'UTF8') {
                     $unicodedb = true;
                 }
             }