I am a new to php. I am using php ver 4.0.3 and MySQL.

I have wrote two files and I'd like to pass some varaibles from first file to use them in the second file.
but the values did not displayed in the second file(nothing print out). and also I want to pass them to anothr file ... here is what I've wrote :

******** file1.php**********
$user_addres="User Address";

print "<FORM action='file2.php' method=post>";
print "<input type=submit value='send'>";
print "<INPUT TYPE='hidden' NAME='UserName' VALUE='$username'>\n";
print "<input type=hidden name=UserNum' value='$user_num'>";
print "<input type=hidden name='Addrress' value='$user_addres'>";
print "</td>";
print "</FORM></tr>";

** second file file2.php ****

<FORM action='anothrfile.php' method=post>

    print "<INPUT TYPE='hidden' NAME='User_name' VALUE='$UserName'>";
    print "<input type=hidden name=User_Num' value='$UserNum'>";
    print "<input type=hidden name='User_Addres' value='$Address'>";

<tr><th align=left >Name:</th><td ><? print "$User_name"; ?></td></tr>
<tr><th align=left >User Number:</th><td > <? print "$User_Num"; ?></td></tr>
<tr><th align=left >Address:</th> <td ><? print"$User_Addres"; ?></td></tr>
<input type=submit value='submit'>

Kind Regrads Adam I hope someone can help me. Thanks

Stay in touch with absent friends - get MSN Messenger http://www.msn.co.uk/messenger

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

Reply via email to