문자열 charset 변경하고 반환 - string iconv ( string $in_charset , string $out_charset , string $str )
2014. 1. 13. 00:31
- <?php
- $text = iconv("UTF-8", "euc-kr", $text);
- $text = iconv("euc-kr", "UTF-8", $text);
- $text = iconv("UTF-8", "euc-jp", $text);
- $text = iconv("UTF-8", "ISO-8859-1", $text);
- ?>
--------------------------------------------------------------------------------------------
string iconv ( string $in_charset , string $out_charset , string $str )
2.~5. 라인
$str문자열을 $in_charset에서 $out_charset으로 변경하고 문자열을 반환합니다.
이 함수를 사용하기 위해서는 php 컴파일시 --with-iconv[=DIR]옵션을 지정해야합니다.
이 함수 결과는 보여주기 애매해서 생략합니다.