I have a form and have some fields in it. Check box is also fields for hobbies and when i submit that form then values are inserted in database and it redirect to another form and show the values from database in table format.But I have a problem when showing the result in table manner is it is not showing the values of all selected check boxes it just show the last selected check box's value. And one more thing can i show password in * form or hash form not just simple text form when showing in table format
<head>
<title>Sunil1</title>
</head>
<?php
mysql_connect("localhost","root","")or die("Unable to create to connection");
mysql_select_db("sunil") or die(mysql_error());
$Name1=$_POST["t1"];
$Name2=$_POST["t2"];
$Sex=$_POST["sex"];
$Country=$_POST["Country"];
$Hobby=$_POST["check"];
$Email=$_POST["t3"];
$Pass=$_POST["p1"];
$Repass=$_POST["p2"];
$sql="INSERT INTO registration (First_Name,Last_Name,Sex,Country,Hobbies,Email,Password,Repassword) VALUES('$Name1','$Name2','$Sex','$Country','$Hobby','$Email','$Pass','$Repass')";
mysql_query($sql);
print"Data Submitted Successfully";
$result = mysql_query("SELECT * FROM registration");
print "<table border=1>";
while($row = mysql_fetch_array($result))
{
print "<tr>";
print "<td>".$row['First_Name']."</td>";
print "<td>".$row['Last_Name']."</td>";
print "<td>".$row['Sex']."</td>";
print "<td>".$row['Country']."</td>";
print "<td>".$row['Hobbies']."</td>";
print "<td>".$row['Email']."</td>";
print "<td>".$row['Password']."</td>";
print "<td>".$row['Repassword']."</td>";
print "</tr>";
}
print "</table>";
?>