PHP convert_cyr_string() 関数

❮ PHP 文字列リファレンス

文字列をある文字セットから別の文字セットに変換します:

<?php
$str = "Hello world! �øå";
echo $str . "<br>";
echo convert_cyr_string($str,'w','a');
?>
例の実行 »

定義と用法

convert_cyr_string() 関数は、文字列をあるキリル文字セットから別の文字セットに変換します。

サポートされているキリル文字セットは次の通りです:

注: この関数はバイナリセーフです。


構文

convert_cyr_string(string,from,to)

パラメータ 説明
string 必須。 変換する文字列
from 必須。変換元のキリル文字セットを指定する文字
to 必須。変換先のキリル文字セットを指定する文字

技術内容
返り値: 変換した文字列を返します
PHP バージョン: 4+

❮ PHP 文字列リファレンス