Created
June 15, 2013 08:39
-
-
Save githiro/5787419 to your computer and use it in GitHub Desktop.
PHP: escape all in array function
This file contains hidden or 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 escapeAllInArray($array) | |
| { | |
| foreach ($array as $key => $value) | |
| { | |
| $array[$key] = htmlspecialchars($value, ENT_QUOTES, $charset); | |
| } | |
| return $array; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment