Question: > 
> **Possible Duplicate:**  
> 
> [How does the Google “Did you mean?” Algorithm work?](https://stackoverflow.com/questions/307291/how-does-the-google-did-you-mean-algorithm-work) 
> 
> 
> 

I have a database table with about 2 million records. I'm using mysql fulltext to searching but users very often enter bad words ex gmes -> should be games so I need a library with PHP wrappers to have feature like in google 'did you mean' What should I use?

Answer: 
You could use an API like Yahoo's [Spelling Suggestion](http://developer.yahoo.com/search/web/V1/spellingSuggestion.html) as any easy way of completing it with out having to roll your own.
Another option would be the [PHP Pspell functions](http://www.php.net/manual/en/ref.pspell.php) in particular [pspell\_suggest](http://www.php.net/manual/en/function.pspell-suggest.php), but you need to install the [aspell library](http://aspell.net/) on the server.