函数名称:pspell_store_replacement()
适用版本:PHP 4 >= 4.0.2, PHP 5, PHP 7
函数描述:将一个单词的拼写建议添加到拼写词典中,并指定其替换值。
用法: bool pspell_store_replacement ( int $dictionary_link , string $misspelled , string $correct )
参数:
返回值: 如果成功添加了拼写替换,则返回 true,否则返回 false。
示例:
// 创建一个英语拼写词典链接
$pspell_link = pspell_new("en");
// 添加拼写替换
$misspelled = "recieve";
$correct = "receive";
if (pspell_store_replacement($pspell_link, $misspelled, $correct)) {
echo "拼写替换添加成功!";
} else {
echo "拼写替换添加失败!";
}
注意事项: