PHP character garbled,charactergarbled
MYSQL Console Query is garbled
The database&table character set is not the same as the character set shown on the MySQL console
Right-click the MySQL console border Click Properties to see whether the character set mode of the current code page is the same as the database's character set mode
View database character Set show variables like '%char% ';
The main look is:character-set-client=gbk character-set-server=gbk character-set-result=gbk is the same
FIX: Set database character mode
Alert database database_name default character set GBK;
Alert database database_name Default character set UTF8 default collate utf8_geberal_ci;
Collate Utf8_geberal_ci:utf8 character Proofing mode GBK did not find proofreading, please leave a message.
No effect please open My.ini modify DEFAULT-CHARACTER-SET=GBK CHARACTER-SET-SERVER=GBK
When created, specify:
CREATE DATABASE database_name character Set GBK;
page garbled : Find page properties on Dreamware set character mode
If there is a link MySQL should remain unified
Database + page Character Set +html head +mysql in PHP link character (set names GBK)
The query database in the page gets garbled: MySQL, page character set, MySQL and PHP transfer characters are the same
Set Apache configuration file httpd.conf Add or modify Apache default character startup mode: Adddefaultchars GBK
Direct set transfer character mysql> set names GBK
mysql_query ("Set names GBK", $conn);
Mysql_close ();
?>
http://www.bkjia.com/PHPjc/980030.html www.bkjia.com true http://www.bkjia.com/PHPjc/980030.html techarticle PHP character garbled,charactergarbled mysql console query when there is garbled databasetable character set in the MySQL console display the character set is not the same right-click the MySQL console border ...