note 13688 deleted from function.stripslashes by aidan

From: Date: Sun, 29 Aug 2004 10:24:08 +0000
Subject: note 13688 deleted from function.stripslashes by aidan
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-75541@lists.php.net to get a copy of this message
Note Submitter: russ at zerotech dot net ---- In case you're wondering how to strip slashes on all the elements in an array: function stripslashes_array($arr = array()) { $rs = array(); while (list($key,$val) = each($arr)) { $rs[$key] = stripslashes($val); } return $rs; } Very useful for using on all the elements in say $HTTP_POST_VARS, or elements returned from an database query. (to addslashes, just change strip to add =)

« previous php.notes (#75541) next »