Hi,
The supervisor of my system wants to modify customer details. I created this modify_form.php page.
But when i modifies one record of a particular customer it affected to all the records. Therefore all the records contain same thing.....
Can anyone give me the correct coding which modifies only that record.
This is my modify_form.php page.
<?php
$connect=mysql_connect("localhost","root","");
mysql_select_db("bank",$connect) or die ("could not select database");
$nic = '';
$full_name = '';
$name_with_initials = '';
$address = '';
$contact_number = '';
$gender = '';
$nic =$_POST['nic'];
$full_name =$_POST['full_name'];
$name_with_initials =$_POST['name_with_initials'];
$address =$_POST['address'];
$contact_number =$_POST['contact_number'];
$gender =$_POST['gender'];
$result = mysql_query("UPDATE customer SET nic = '$nic', full_name = '$full_name', name_with_initials = '$name_with_initials', address = '$address', contact_number = '$contact_number', gender = '$gender'") ;
if($result){
echo "Your information has been successfully added to the database.";
}else{
echo "Failed";
}
?>
Thanks,