php imagettftext乱码的解决办法:首先通过“mb_convert_encoding”函数进行转码;然后通过语句“mb_convert_encoding($str, "UTF-8", "GB2312");”输出即可。
推荐:《PHP视频教程》
php 使用ImageTTFText 中文出现乱码:
可以用
string mb_convert_encoding ( string $str, string $to_encoding [, mixed $from_encoding] )来进行转码,再输出
如
$str = mb_convert_encoding($str, "UTF-8", "GB2312");确认一下文件是不是utf-8的。
以上就是如何解决php imagettftext 乱码问题的详细内容!
查看更多关于如何解决php imagettftext 乱码问题的详细内容...
声明:本文来自网络,不代表【好得很程序员自学网】立场,转载请注明出处:http://www.haodehen.cn/did53552
如何解决php imagettftext 乱码问题
阅读:38次