-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathget_client.php
34 lines (33 loc) · 898 Bytes
/
get_client.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
<?php
require_once 'dbconnect.php';
$search = $_POST['name'];
$query = "SELECT * FROM client WHERE fullname LIKE '%$search%' ";
$result = $connect->query($query); ?>
<p style="text-align: center"> <b> Current Client list </b></p>
<table class="table table-hover" style="width:100%;">
<thead>
<tr>
<th>ID</th>
<th>Full Name</th>
<th>Email</th>
<th>Phone</th>
<th>Address</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<?php
while ($row = $result->fetch_assoc()) { ?>
<tr>
<td><?php echo $row['id']; ?></td>
<td><?php echo $row['fullname']; ?></td>
<td><?php echo $row['email']; ?></td>
<td><?php echo $row['phone']; ?></td>
<td><?php echo $row['address']; ?></td>
<td><button type="button" class="btn btn-danger"> Delete</button></td>
</tr>
<?php
}
?>
</tbody>
</table>