Php/docs/function.pspell-suggest

提供:Dev Guides
< Php
2020年12月14日 (月) 11:56時点におけるNotes (トーク | 投稿記録)による版 (autoload)
(差分) ← 古い版 | 最新版 (差分) | 新しい版 → (差分)
移動先:案内検索

pspell_suggest

(PHP 4 >= 4.0.2, PHP 5, PHP 7)

pspell_suggest単語のスペルについて修正候補を示す


説明

pspell_suggest ( int $dictionary , string $word ) : array|false

pspell_suggest() は、 指定した単語について可能性のあるスペルの配列を返します。


パラメータ

dictionary
word
調べたい単語。


返り値

修正候補の配列を返します。


例1 pspell_suggest() の例

<?php$pspell_link = pspell_new("en");if (!pspell_check($pspell_link, "testt")) {    $suggestions = pspell_suggest($pspell_link, "testt");    foreach ($suggestions as $suggestion) {        echo "Possible spelling: $suggestion<br />";    }}?>