Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function findArrayWithKeyValue($array, $search_key, $search_value)
- {
- foreach($array as $key=>$value)
- {
- if(is_array($value))
- return findArrayWithKeyValue($value, $search_key, $search_value);
- if($key == $search_key &&
- $value == $search_value)
- return $array;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement