Created
November 10, 2015 23:24
-
-
Save letitride/3afee9f32b67840e5289 to your computer and use it in GitHub Desktop.
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 array_filter_recursive($input) | |
{ | |
foreach ($input as &$value) { | |
if (is_array($value)) { | |
$value = array_filter_recursive($value); | |
} | |
} | |
return array_filter($input); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment