2,mb_convert_encoding函数语法 : /* Convert internal character encoding to SJIS */$str = mb_convert_encoding($str, "SJIS");/* ">
输入banner图图片脚本导航/分类

php编码转换函数(iconvmb_convert_encoding)

  1. echo iconv("ISO-8859-1", "UTF-8", "This is a test.");
  2. ?>

2,mb_convert_encoding函数语法 :

  1. /* Convert internal character encoding to SJIS */

  2. $str = mb_convert_encoding($str, "SJIS");

  3. /* Convert EUC-JP to UTF-7 */

  4. $str = mb_convert_encoding($str, "UTF-7", "EUC-JP");

  5. /* Auto detect encoding from JIS, eucjp-win, sjis-win, then convert str to UCS-2LE */

  6. $str = mb_convert_encoding($str, "UCS-2LE", "JIS, eucjp-win, sjis-win");

  7. /* "auto" is expanded to "ASCII,JIS,UTF-8,EUC-JP,SJIS" */

  8. $str = mb_convert_encoding($str, "EUC-JP", "auto");
  9. ?>