Re: POST problem

From: Date: Tue, 28 Aug 2001 18:16:46 +0000
Subject: Re: POST problem
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-64858@lists.php.net to get a copy of this message
My guess is that your register_globals config option is off: http://php.he.net/manual/en/configuration.php#ini.register-globals (I believe that recent versions of PHP have it off by default). You should be able to access the values you want via $HTTP_POST_VARS['name'] and $HTTP_POST_VARS['age'] -steve At 10:39 AM -0700 8/28/01, Mashrab Kuvatov wrote:
Hi everybody, i'm a newie in php, but i have a general understanding of it. Recently, i've installed PHP as a static module on my Apache-1.3.19 and tried an example i read in PHP tutorial. Assume you have a page with a form like this on it: <form action="action.php" method="post"> Your name: <input type="text" name="name"> You age: <input type="text" name="age"> <input type="submit"> </form> and action.php like this Hi <?php echo $name; ?>. You are <?php echo $age; ?> years old. This action.php is supposed to print out values one enters to the form fields. Right? So, my problem is that it doesn't. Instead, it prints Hi.You are years old. Can anyone help me to figure it out or to point me to the right direction so in future i won't annoy you with my silly questions. Thanks in advance, Mashrab.
-- +------------------------ Open source questions? ------------------------+ | Steve Edberg University of California, Davis | | sbedberg@ucdavis.edu Computer Consultant | | http://aesric.ucdavis.edu/ http://pgfsun.ucdavis.edu/ | +----------- http://pgfsun.ucdavis.edu/open-source-tools.html -----------+

« previous php.general (#64858) next »