/ Published in: PHP

Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
"php", "javascript", "css" ); $word = "japhp"; $best_match = $dictionary[0]; foreach($dictionary as $w) { if( $value < $match_value ) { $best_match = $w; $match_value = $value; } } echo "Did you mean the '$best_match' category?";
URL: http://uk.php.net/levenshtein
Comments
