-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathser.php
More file actions
93 lines (78 loc) · 1.73 KB
/
ser.php
File metadata and controls
93 lines (78 loc) · 1.73 KB
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
<!DOCTYPE html>
<html>
<head>
<title>Service: Request</title>
</head>
<body style="background:linear-gradient(rgba(0,0,0,0.5),rgba(0,0,0,0.5)),url(images/feed.jpg); background-size:cover;">
<style type="text/css">
table{
margin: 3 auto;
display: table-cell;
vertical-align: middle;
height: 20%;
width: 85%;
display: table;
border-collapse:collaspe;
color:#d96459;
font-family:monospace;
font-size:20px;
text-align: left;
}
th {
background-color:#588c7e;
color:white;
}
.data{
background-color:white;
color:black;
}
h2{
color: white;
}
</style>
<body>
<?php
$cn = new mysqli("localhost","root","","owner") or die('not connected');
$query = "SELECT * FROM servin";
$data = mysqli_query($cn, $query);
echo $cn->error;
if($data)
$total = mysqli_num_rows($data);
if ($total != 0) {
?>
<h2>Services Details</h2><br>
<table>
<thead>
<tr>
<th>Vehicle no</th>
<th>Engine Service</th>
<th>Oil Filtration</th>
<th>Wash Service</th>
<th>One-Day Service</th>
<th>Completed</th>
</tr>
</thead>
<tbody>
<form action="open1.php" method="POST">
<?php
while ($result = mysqli_fetch_assoc($data))
{
echo "<tr class='data'>
<td>".$result['vehno']."</td>
<td>".$result['engineservice']."</td>
<td>".$result['oilservice']."</td>
<td>".$result['waterservice']."</td>
<td>".$result['enginereplace']."</td>
<td><input type='checkbox' name='".$result['vehno']."'value='".$result['vehno']."'></td>
</tr>";
}
}
?>
<tr><td><input type="submit" name="updatestatus"></td>
<td><button><a href='admin.html'>Back</button></a></button></td>
</tr>
</form>
</tbody>
</table>
</body>
</html>