This beautifies it (even makes it a bit more secure), but one doesn't need it 
really; should have worked without these changes, too. (Of course, it's 
better to include these changes)

Sascha

> The value of name for the submit button is wrong - it should be the same
> as the value you gave the isset statement, in this case it should be
> <input type="submit" name="name" value="sendit">
> Better yet is to use isset($submit) and the value for the submit
> statement is also name="submit" -
> <input type="submit" name="submit" value="sendit">
> of course value is optional. So you end up with this -
>
> <?
> if (isset($_GET['submit']))
>       {
>       echo "Hallo ".$GET['name'];
>       }
> else
>       {
>       echo "<FORM action='test.php' method=get>
>       <input type='text' name='name'>
>       <input type='submit' name='submit' value='sendit'>";
>       }
> ?>


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to