From http://stackoverflow.com/questions/15944824/search-a-php-array-for-string-match