Created
September 30, 2016 20:16
-
-
Save yavir-me/83feb2d6ab9bba8e9c1a896ee5b68acd to your computer and use it in GitHub Desktop.
in array insensitive execution
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function inArrayI($needle, $haystack) { | |
return in_array(strtolower($needle), array_map('strtolower', $haystack)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment