RE: [PHP-WIN] COMPLETE! newby
| From: | Warren Vail | Date: | Thu, 26 Jun 2003 01:47:40 +0000 |
| Subject: | RE: [PHP-WIN] COMPLETE! newby | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-20570@lists.php.net to get a copy of this message | ||
check http://us4.php.net/register_globals. there
is a good explanation
there.
Warren Vail
warren@vailtech.net
-----Original Message-----
From: JAY REIDY [mailto:jay.reidy@verizon.net]
Sent: Wednesday, June 25, 2003 5:23 PM
To: php-windows@lists.php.net
Subject: [PHP-WIN] COMPLETE! newby
I just installed PHP and Apache on everyone's favorite OS, Windows XP. Both
more or less work as advertised, and I'm using them for development at home.
When I use this form:
<form action="foo.php" method="post">
Name: <input type="text" name="username"><br>
Email: <input type="text" name="email"><br>
<input type="submit" name="submit" value="Submit me!">
</form>
to call this PHP script:
<?php
print $_POST['username'];
print $_REQUEST['username'];
import_request_variables('p', 'p_');
print $p_username;
print $HTTP_POST_VARS['username'];
print $username;
?>
I get this error:
Notice: Undefined variable: username in C:\Program Files\Apache
Group\Apache2\htdocs\myserver\foo.php on line 18
which happens to be the "print $username" command.
Obviously, the HTML form isn't passing the values to the script.
Does ANYone have a clue? I have an idea there's a switch or something I
don't have right in my Apache config file but any help would be appreciated.
Peace,
j
--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php