Dear Sir/Madam,
     I have create table for reservation system in that table i need to save
all the values
but it couldn`t save all the values it saves only the last value.
  Please help me!
$db = mysql_connect("localhost", "kumar","");
$sql = "INSERT INTO personalmst (setdate,name, uid, password, bumon,email)
VALUES ('$setdate','$name', '$uid', '$password','$bumon','$email')";
$result = mysql_query($sql);
 if(!($_POST['password'] == $_POST['confirmpassword'])) //Does their
passwords match?
 echo " Your password do not match!";
 echo "Thank you! Information entered.\n";
<form method="post" action="Master.php" >
Setdate:<input type="text" name="setdate"><br>
First name:<input type="Text" name="name"><br>
UserID:<input type="Text" name="uid"><br>
Password:<input type="password" name="password"><br>
 Confirm Password:<input type="text" name="confirmpassword"><br>
Department:<SELECT NAME="bumon">
<?php $db = mysql_connect("localhost", "kumar")
OR DIE("Unable to connect to database");
$result = mysql_query("SELECT bumon FROM personalmst",$db);
 echo("<option value=\"\"></option>");
while($myrow = mysql_fetch_array($result))
    printf("<option value=\"%s\">%s</option>\n",
E-mail:<input type="Text" name="email"><br>
<input type="Submit"name="submit" value="Register">
<input type="reset" name="cancel" value="cancel">
<input type="button" name=update value=update
<td align="right"><a href="Bumon.php" align="right">MasterCheck</a>

Reply via email to