SAbsar
Mac Graduate
Hi.
I'm just learning PHP, and I tried it out with forms, but it doesnt work. I mean the php script doesnt read the variables from the previous page!
for an example, if in the calling HTML page,
<form method='post' action='test.php'>
<input type='text' name='fname' value='Absar'>
<input type='submit' name='submit' value='Submit'>
</form>,
and in the test.php file,
<?php
print "Hello, ";
print $fname;
?>
it DOESNT print fname!!! Its printing "Hello, ", but not fname!
I cant figure out what im doing wrong! ive also tried GET instead of POST, but nothing works!
Help me out, will ya?
I'm just learning PHP, and I tried it out with forms, but it doesnt work. I mean the php script doesnt read the variables from the previous page!
for an example, if in the calling HTML page,
<form method='post' action='test.php'>
<input type='text' name='fname' value='Absar'>
<input type='submit' name='submit' value='Submit'>
</form>,
and in the test.php file,
<?php
print "Hello, ";
print $fname;
?>
it DOESNT print fname!!! Its printing "Hello, ", but not fname!
I cant figure out what im doing wrong! ive also tried GET instead of POST, but nothing works!
Help me out, will ya?