I am trying to find closest match from an array. For this I use levenshtein()
, but levenshtein()
returns only first matched string or first closest match.
Here is my scenario:
$words = array('Break Noise','Engine Noise','Vehicle is jerking');
If my input is Noise
, I want to get both Break Noise
and Engine Noise
.
Is it possible to do?
levenshtein()
returns me only Break Noise
which is the first element.