Bug #825 - Database collation for newly created courses always will be utf8_general_ci

skala
Ivan Tcholakov 16 years ago
parent 1aef40239f
commit 03bb4df9ec
  1. 16
      main/inc/lib/add_course.lib.inc.php

@ -1,17 +1,17 @@
<?php //$id: $ <?php
/* For licensing terms, see /license.txt */ /* For licensing terms, see /license.txt */
/** /**
* This is the course creation library for Dokeos. * This is the course creation library for Chamilo.
* It contains functions to create a course. * Include/require it in your code for using its functionality.
* Include/require it in your code to use its functionality.
* *
* @package dokeos.library * @package dokeos.library
* @todo clean up horrible structure, script is unwieldy, for example easier way to deal with * @todo clean up horrible structure, script is unwieldy, for example easier way to deal with
* different tool visibility settings: ALL_TOOLS_INVISIBLE, ALL_TOOLS_VISIBLE, CORE_TOOLS_VISIBLE... * different tool visibility settings: ALL_TOOLS_INVISIBLE, ALL_TOOLS_VISIBLE, CORE_TOOLS_VISIBLE...
*/ */
require_once (api_get_path(LIBRARY_PATH).'database.lib.php'); require_once api_get_path(LIBRARY_PATH).'database.lib.php';
require_once (api_get_path(LIBRARY_PATH).'mail.lib.inc.php'); require_once api_get_path(LIBRARY_PATH).'mail.lib.inc.php';
/* /*
============================================================================== ==============================================================================
@ -254,7 +254,9 @@ function update_Db_course($courseDbName, $language = null)
if (empty($language)) { if (empty($language)) {
$language = $language_interface; $language = $language_interface;
} }
$charset_clause = Database::make_charset_clause('UTF-8', $language);
//$charset_clause = Database::make_charset_clause('UTF-8', $language); // A problematic choice, see Bug #825
$charset_clause = ' DEFAULT CHARACTER SET utf8 DEFAULT COLLATE utf8_general_ci';
if (!$_configuration['single_database']) if (!$_configuration['single_database'])
{ {

Loading…
Cancel
Save