当前位置: 首页> 函数类别大全> metaphone

metaphone

计算字符串的metaphone键
名称:metaphone
分类:字符串
所属语言:php
一句话介绍:计算字符串的 metaphone 键。

定义和用法

metaphone() 函数计算字符串的 metaphone 键。

metaphone 键代表字符串的英语发音。

metaphone() 函数可用于拼写检查程序。

注释:metaphone() 函数为发音相似的单词创建相同的键。

注释:所生成的 metaphone 键长度可变。

提示:metaphone() 比 soundex() 函数更精确,因为 metaphone() 了解英语发音的基本规则。

语法

metaphone(string,length)
参数 描述
string 必需。规定要检查的字符串。
length 可选。规定 metaphone 键的最大长度。
同类函数
  • 将字符串的第一个字符设为大写 ucfirst

    ucfirst

    将字符串的第一个字符设为大写
  • 返回使用 htmlspecialchars() 和 htmlentities() 后的转换表 get_html_translation_table

    get_html_translation_table

    返回使用htmlspecialchars
  • 将字符由一种 Cyrillic 字符转换成另一种 convert_cyr_string

    convert_cyr_string

    将字符由一种Cyrillic字符转换成另
  • 从字符串的开头删除空格(或其他字符) ltrim

    ltrim

    从字符串的开头删除空格(或其他字符)
  • implode的别名 join

    join

    implode的别名
  • 将格式化的字符串写入流 vfprintf

    vfprintf

    将格式化的字符串写入流
  • 替换字符串的子串 substr_replace

    substr_replace

    替换字符串的子串
  • 打断字符串为指定数量的字串 wordwrap

    wordwrap

    打断字符串为指定数量的字串
热门文章