Is there anyone who helps me solve a linux garbled problem (after a day)
Source: Internet
Author: User
Are there any good guys to help me solve a linux garbled problem (after a day) I am using a ubuntu linux system, and the data in the mysql database is normally displayed in Chinese, but does the text entered in the PHP file display garbled characters on the display? (Utf8 encoding is used by default. if it is changed to gb2312, the encoding page of mysql cannot be used. Are there any good guys to help me solve a linux garbled problem (after a day)
I am using a ubuntu linux system. The data obtained from the mysql database is displayed in Chinese, but the Chinese entered in the PHP file is indeed garbled on the display? (The system uses utf8 encoding by default. if it is changed to gb2312, the mysql encoding page is all utf8. if it is changed to gb2312, the encoding page will not work.) What is the problem?
------ Solution --------------------
This is not very closely related to the system encoding, right?
Mainly browser encoding
Database encoding
Database data ID
Php file encoding
Php and html header contentype encoding
Php database access encoding set names utf8
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service