PHP中GBk编码转换为UTF-8,UTF-8编码转换为GBK

首先是GBK转UTF-8

$data=iconv(“GBK”,”UTF-8//IGNORE”,$data);

然后是UTF-8转GBK

$content=iconv(“UTF-8″,”GBK//IGNORE”,$content); 

发布者:梧桐细雨,转转请注明出处:https://www.binbinbiji.com/php/2163.html

发表评论

邮箱地址不会被公开。 必填项已用*标注

蜀ICP备14017386号-13