Re: variables not being passed
| From: | Patrik Bengtsson | Date: | Wed, 21 Jun 2000 12:25:28 +0000 |
| Subject: | Re: variables not being passed | ||
| Groups: | php.windows | ||
| Request: | Send a blank email to php-windows+get-561@lists.php.net to get a copy of this message | ||
>
>
>*********** REPLY SEPARATOR ***********
>
>On 21-06-2000 at 10:00 Adrian Teasdale wrote:
>
>>Hi all
>>
>>I am having a weird problem with PHP in that it is not passing variables
>>from page to page, either in a form or via URL.
>>
>>Here is an example of a test script I've run:
>>
>><form method="post" action="testvariables.php">
>>// this file passes posts to itself
>>
>>Please type your name here:<br>
>><input type="text" name="username"<br><br>
>><input type="submit" value="Enter Name">
>></form>
>><?php
>>echo $username;
>>?>
>try echo $HTTP_POST_VARS["username"]
>
There's a typo that might give you a problem:
<input type="text" name="username"<br><br>
~~
Should read
<input type="text" name="username"> <br><br>
That might help..
/Patrik
Patrik Bengtsson
Systemutveckling / Projektering
[prestanda.com]
patrik@prestanda.com
040 - 91 56 50
0708- 12 38 55