note 15082 deleted from language.variables by irc-html

From: Date: Sat, 19 Jan 2002 18:47:58 +0000
Subject: note 15082 deleted from language.variables by irc-html
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-25182@lists.php.net to get a copy of this message
PROBLEM: environment variable HTTP_POST_VARS undefined (Since many people with this problem will probably search THIS place, I'll put this snippet here.) SOLUTION: When you're inside a function, don't forget to declare $HTTP_POST_VARS or imported form identifiers as GLOBALS, because otherwise you won't REACH them from inside the function. Instead, PHP will always state: 'Undefined variable ...'. (I was nearly desperating after 2 days with this stupid problem.) Use: function xy() { global $HTTP_POST_VARS; ... and things will be ok. Regards, Daniel

« previous php.notes (#25182) next »