Is there a function to search array for multiple strings?

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
impulse()
Forum Regular
Posts: 748
Joined: Wed Aug 09, 2006 8:36 am
Location: Staffordshire, UK
Contact:

Is there a function to search array for multiple strings?

Post by impulse() »

Array_search did crop up on php.net but it doesn't seem to be able to handle searching for multiple strings. For example I have an array and I want a function that will return whether it has found "a", "b", "h" or "z" within that array. Does this function already exist? Or will I have to run array_search multiple times?


Regards,
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

Multiple times most likely.
Post Reply