mysql 需要做的是:
这是在创建数据库的时候需要是utf-8格式
my.cnf或者my.ini
[mysql]
default-character-set = utf8
default-character-set = utf8
character-set-server = utf8
collation-server = utf8_general_ci
init_connect = 'SET collation_connection = utf8_general_ci'
init_connect = 'SET NAMES utf8'
这是在创建数据库的时候需要是utf-8格式
my.cnf或者my.ini
引用
[mysql]
default-character-set = utf8
default-character-set = utf8
character-set-server = utf8
collation-server = utf8_general_ci
init_connect = 'SET collation_connection = utf8_general_ci'
init_connect = 'SET NAMES utf8'