I'm trying to use array_search to check if an element is in an array, but the problem is that it returns false if the element exists in first position.
My code is:
$blah = array ('a', 'h', 'k');
$searchfor = 'a';
if (array_search ($searchfor, $blah, true)) echo "it's in there";
How do I fix this? thanks