Try adding mysql_query("SET NAMES UTF8");? Or check the encoding settings of the database through the command line: show variebles like "character_set_%"; focus on whether the values of "character_set_client", "character_set_connection", and "character_set_results" are all set to utf8
Sometimes the encoding format written in the program is UTF-8, but garbled characters appear when displayed. The reason may be related to the editor. Some editors on Windows have certain problems. It is recommended to change the compiler and try again
First of all. Must be uniformly coded. Different operating systems sometimes have different encodings. For example, I use Linux for work and sometimes the exported documents will be garbled on Win
Try adding mysql_query("SET NAMES UTF8");? Or check the encoding settings of the database through the command line: show variebles like "character_set_%"; focus on whether the values of "character_set_client", "character_set_connection", and "character_set_results" are all set to utf8
Check whether the relevant folder names are in Chinese
Sometimes the encoding format written in the program is UTF-8, but garbled characters appear when displayed. The reason may be related to the editor. Some editors on Windows have certain problems. It is recommended to change the compiler and try again
Check the database connection form to see if it is utf-8
You did not select the encoding when importing the data, and the data imported into the database is already garbled
header("Content-Type: text/html;charset=utf-8");
Open the file with a text editor, then save it as UTF-8, save it, overwrite the previous file, solve it, OK
First of all. Must be uniformly coded. Different operating systems sometimes have different encodings. For example, I use Linux for work and sometimes the exported documents will be garbled on Win
Try to look at the encoding of the browser. Just make sure that the encoding of files, pages, and browsers are all consistent.