-
Notifications
You must be signed in to change notification settings - Fork 0
/
update1.php
27 lines (26 loc) · 955 Bytes
/
update1.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php
$con=mysqli_connect("localhost","root","","priyanka") or die(mysqli_connect_error($con));
$r1=$_POST['fnm'];
$r2=$_POST['lnm'];
$r3=$_POST['jbtl'];
$r4=$_POST['sal'];
$r5=$_POST['addr'];
$r6=$_POST['gen'];
$r7=$_POST['dob'];
$r8=$_POST['eml'];
$r9=$_POST['eid'];
$update_query="update employee set first_name='$r1',
last_name='$r2',
job_title='$r3',
salary='$r4',
address='$r5',
gender='$r6',
date_of_birth='$r7',
email='$r8'
where id='$r9'" ;
$update_query_result=mysqli_query($con,$update_query);
echo '<script language="javascript">';
echo 'alert("Record Updated Successfully");';
echo 'location.href="display.php";';
echo '</script>';
?>