Problem with this tutorial...
Posted: Wed Mar 12, 2003 5:38 pm
Okay, I just got a book..."SAMS Teach Yourself PHP in 24 Hours". I am on hour 9 "How to create and retrieve user data". It shows the following things:
and the process.php is this:
This was copied word for word from the book. When I enter my name and address in the boxes, it comes up on the process.php page like this:
Welcome
Your address is:
and leaves it blank. Please post how to fix and what the book is missing. Thanks
Code: Select all
<HTML>
<HEAD>
<TITLE>Listing 9.2 a Simple HTML Form</TITLE>
</HEAD>
<BODY>
<form action="process.php">
<input type="text" name="user">
<br>
<textarea name="address" rows="5" cols="40">
</textarea>
</FORM>
</BODY>
</HTML>Code: Select all
<HTML>
<HEAD>
<TITLE>Listing 9.3 Reading input from the form in Listing 9.2</TITLE>
</HEAD>
<BODY>
<?php
print "Welcome <b>$user</b><P>\n\n";
print "Your address is:<P>\n\n<b>$address</b>";
?>
</BODY>
</HTML>Welcome
Your address is:
and leaves it blank. Please post how to fix and what the book is missing. Thanks