Re: Problem with HTTP variables

From: Date: Tue, 25 May 2004 21:39:11 +0000
Subject: Re: Problem with HTTP variables
References: 1  Groups: php.install 
Request: Send a blank email to php-install+get-13555@lists.php.net to get a copy of this message
I had actually been trying to just use $variable_name. That's the way it was taught to me way back when, but it's probably bad practice. When I use $_GET[name] it works just fine. Thanks so much for the help. -Joe "Jeffrey N Dyke" <jeffrey_n_Dyke@Keane.com> wrote in message news:OF4A5A6426.A158434E-ON85256E9F.0075BEED@keane.com... > > > > >I've installed PHP on my Apache 2.0 for Windows XP, and I'm having a wierd > >problem where php works like it's supposed to except for that it won't > read > >any variables I try to feed it via HTTP, like index.php?page=pictures. it > >just thinks I left page blank. > > >Is this an apache problem, or is this a PHP problem, and can anybody help > me > >fix it? > > > This is most likely a register_globals problem. Are you referencing the > variable by $variable_name or $_GET['variable_name'] which in your case is > $_GET['page'] > > You should use the $_GET/$_POST/$_SESSION/$_COOKIE method. You can also > use $HTTP_POST_VARS, although i perfer the former. > > HTH > Jeff

« previous php.install (#13555) next »