oscommerce - set mysql database codepage to utf8



oscommerce 2.2
file includes/functions/database.php - after line
if ($$link) mysql_select_db($database);
add line:
mysql_query("SET NAMES utf8;",$$link);


oscommerce 3.x
file includes/classes/database/mysqli.php - after lines
if ( version_compare(mysqli_get_server_info($this->link), '5.0.2') >= 0 ) {
    $this->simpleQuery('set session sql_mode="STRICT_ALL_TABLES"');
}
add line:
$this->simpleQuery('set names utf8');
Last update:
2010-03-24 08:37
Author:
Daniel
Revision:
1.3
Average rating:0 (0 Votes)

You can comment this FAQ

Chuck Norris has counted to infinity. Twice.