help with guestbook
hi
i'm new to php and want to learn. i set up the apache server under win2k
and installed the php.installer package. then i got mysql and everything
goes smooth, when do small things like "hello world" and so.
i'm also able to set up databases in mysql, but when it gets to the tutorial
for a guestbook from Tony Awtrey (php.net developers resources) it
gets to an end.
i set up the database, and created the guestbook.php file copying his
code. when i open the page, i get an error in the field "your name"
<br><b>Warning</b>: Undefined variable: name in
<b>c:\apache\htdocs\guestbook.php</b> on line <b>83</b><br>
line 83reads: VALUE="<?php echo $name; ?>">
the same for the field "your email", "enter message"
Warning: Undefined variable: complete in
c:\apache\htdocs\guestbook.php on line 133
(line133 reads: if ($complete == 1) {
any help would be deeply apreciated.
all lines 71-103 are as follows
<?php } ?>
<FORM METHOD="post" ACTION="guest.php">
<PRE>
Your Name: <INPUT
TYPE="text"
NAME="name"
SIZE="20"
MAXLENGTH="50"
VALUE="<?php echo $name; ?>">
Your Email: <INPUT
TYPE="text"
NAME="email"
SIZE="20"
MAXLENGTH="50"
VALUE="<?php echo $email; ?>">
Enter Message:
<TEXTAREA NAME="message" COLS="40" ROWS="8" WRAP="Virtual">
<?php echo $message; ?>
</TEXTAREA>
<INPUT TYPE="submit" VALUE="Add">
</PRE>
</FORM>
<HR>
<?php