-
Notifications
You must be signed in to change notification settings - Fork 0
/
update.php
54 lines (49 loc) · 1.33 KB
/
update.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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<?php
<html>
<form method="post" action="updateinfo.php">
id <input type="text" name="id" >
no of people <input type="password" name="password">
when cooked <input type="text" name="when" >
desc <input type="text" name="desc" >
packed<input type="packed" name="pack" >
temp<input type="text" name="temp" >
pickup<input type="text" name="pick" >
status <input type="text" name="status" >
<input type="submit" name="submit">
$id = $_POST["id"];
$pass = $_POST["password"];
$when = $_POST["when"];
$desc = $_POST["desc"];
$pack = $_POST["pack"];
$temp = $_POST["temp"];
$pick = $_POST["pick"];
$status = $_POST["status"];
$user="root";
$password="";
$host="localhost";
$db_name="Annadhan";
$query = mysql_query("update fdt set
id='$id', password='$pass',
temp='$temp' where status='$status'", $connection);
}
$query = mysql_query("select * from fdt", $connection);
while ($row = mysql_fetch_array($query)) {
echo "<b><a href='updatephp.php?update={$row['id']}'>{$row['whene']}</a></b>";
echo "<br />";
}
?>
}
if (isset($_GET['submit'])) {
echo '<div class="form" id="form3"><br><br><br><br><br><br>
<Span>Data Updated Successfuly......!!</span></div>';
}
?>
<div class="clear"></div>
</div>
<div class="clear"></div>
</div>
</div><?php
mysql_close($connection);
?>
</body>
</html>