PHP - Soundex 函式



語法

string soundex ( string $str )

定義和用法

它用於計算字串的 Soundex 鍵。

返回值

它返回 Soundex 鍵作為字串。

引數

序號 引數及描述
1

字串

它包含輸入字串的資訊。

示例

嘗試以下示例

<?php
   $input = "tutorialspoint";
   echo soundex($input);
?>

這將產生以下結果:

T364
php_function_reference.htm
廣告