Monday, August 04, 2008

MySQL + PHPMyAdmin + UTF-8 = love

Add the following to the [mysqld] section in /etc/mysql/my.cnf:

character_set_server = utf8
collation_server = utf8_general_ci
default-character-set=utf8

Adding AddDefaultCharset UTF-8 to /etc/apache2/conf.d/charset also helps with some web apps.

Tested on Ubuntu 8.04 Hardy

1 comment:

Smarty said...

And bool mysql_set_charset ( string $charset [, resource $link_identifier ] )