note 19861 added to language.variables.predefined

From: Date: Wed, 13 Mar 2002 15:48:34 +0000
Subject: note 19861 added to language.variables.predefined
Groups: php.notes 
Request: Send a blank email to php-notes+get-27728@lists.php.net to get a copy of this message
Sometimes it is useful to check all form-posted variables and prepare them to be inserted again in the form when coming up the second time by replacing the special characters with HTML-specialchars. The following little code worked nice for this purpose: foreach( $HTTP_POST_VARS as $key=>$value ) { $$key = htmlentities(stripslashes($value)); } -- http://www.php.net/manual/en/language.variables.predefined.php http://master.php.net/manage/user-notes.php?action=edit+19861 http://master.php.net/manage/user-notes.php?action=delete+19861 http://master.php.net/manage/user-notes.php?action=reject+19861

« previous php.notes (#27728) next »