Why are the garbled words appearing after running the file?
PHP中文网2018-02-23 15:49:36
php page is utf encoded
header("Content-type: text/html; charset=utf-8");
php page is gbk encoded
header("Content-type: text/html; charset=gb2312");
php page is big5 encoded
header("Content-type: text/html; charset=big5");
Usually the above code is placed on the home page of the php page
The difference between using header or meta to implement PHP page encoding
1. Page encoding
1. 使用 <META http-equiv="content-type" content="text/html; charset=xxx"> 标签设置页面编码