hey i new 2 here and php =) but this problem has been bothering me for about 2 weeks now and i cant continue learning php until i get this stupid error figured out. here it is.
i have the html file"form.html" like so:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<?php
global $user;
global $address;
?>
<form action="eg9.3.php" method="GET">
<input type="text" name="user">
<br>
<textarea name="address" rows="5" cols="40">
</textarea>
<br>
<input type="submit" value="hit it!">
</form>
</body>
</html>
then i have a php file"eg9.3.php" like so:
<html>
<head>
<title>php file</title>
</head>
<body>
<?
print "Welcome <b>$user</b><P>\n\n";
print "Your address is:<P>\n\n<b>$address</b>";
?>
</html>
and it either tells me that $user is undeclard same with $address
or nothing shows up at all...... why is this?
my 'books' all say that i can access the form names with php.. wuts going on wrong here? how can i make it work?
it should print out whatever $user and $address of the form is.