note 30277 added to reserved.variables

From: Date: Wed, 12 Mar 2003 20:30:11 +0000
Subject: note 30277 added to reserved.variables
Groups: php.notes 
Request: Send a blank email to php-notes+get-45169@lists.php.net to get a copy of this message
If you require access to Predefined Variables in different PHP versions and don't wish to mess about with how you access them, this little snippet of code might help you: function fn_http_vars_access() { global $GET_VARS, $POST_VARS, $COOKIE_VARS, $SESSION_VARS, $SERVER_VARS, $ENV_VARS; $parser_version = phpversion(); if ($parser_version <= "4.1.0") { $GET_VARS = $GET_VARS; $POST_VARS = $POST_VARS; $COOKIE_VARS = $COOKIE_VARS; $SESSION_VARS = $HTTP_SESSION_VARS; $SERVER_VARS = $HTTP_SERVER_VARS; $ENV_VARS = $HTTP_ENV_VARS; } if ($parser_version >= "4.1.0") { $GET_VARS = $_GET; $POST_VARS = $_POST; $COOKIE_VARS = $_COOKIE; $SESSION_VARS = $_SESSION; $SERVER_VARS = $_SERVER; $ENV_VARS = $_ENV; } } fn_http_vars_access(); -- http://www.php.net/manual/en/reserved.variables.php http://master.php.net/manage/user-notes.php?action=edit+30277 http://master.php.net/manage/user-notes.php?action=delete+30277 http://master.php.net/manage/user-notes.php?action=reject+30277

« previous php.notes (#45169) next »