06-28-2008, 03:24 PM
|
#2 (permalink)
|
|
The Acquainted
Join Date: May 2008
Posts: 175
Thanks: 9
|
Procedural:
PHP Code:
function cleanGlobal(&$var, $key = null) { if(is_array($var)) { array_walk_recursive($var, 'cleanGlobal'); } else { // How do you want each variable handled? $var = trim(stripslashes(($var)); } } if (count($_POST) > 0) { array_walk_recursive($_POST, 'cleanGlobal'); }
__________________
There are No Stupid Questions. But there a LOT of Inquisitive Idiots.
Last edited by drewbee : 07-07-2008 at 03:27 PM.
|
|
|