-
Notifications
You must be signed in to change notification settings - Fork 0
/
member_search.php
54 lines (37 loc) · 1.17 KB
/
member_search.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
require('db.php');
$name="";
if (isset($_POST['name'])) {
echo "<div class='container'>";
echo "<table class='table table-bordered table-hover mt-3'>";
echo "<tr>";
echo "<th>Mem_Id</th>";
echo "<th>Name</th>";
echo "<th>DOB</th>";
echo "<th>Age</th>";
echo "<th>Package</th>";
echo "<th>Mobile No</th>";
echo "<th>Update</th>";
echo "<th>Delete</th>";
echo "</tr>";
echo "</div>";
$name=$_POST['name'];
$que=mysqli_query($conn,"SELECT * FROM `member` WHERE CONCAT(`mem_id`,`name`,`dob`,`age`,`package`,'mobileno') LIKE '%".$name."%'");
if(mysqli_num_rows($que) > 0){
while($row=mysqli_fetch_array($que))
{
echo "<tr>";
echo "<td>".$row['mem_id']."</td>";
echo "<td>".$row['name']."</td>";
echo "<td>".$row['dob']."</td>";
echo "<td>".$row['age']."</td>";
echo "<td>".$row['package']."</td>";
echo "<td>".$row['mobileno']."</td>";
echo "<td><a href='home.php?id=$row[mem_id]&info=update_member'><i class='fas fa-pencil-alt'></i></a></td>";
echo "<td><a href='home.php?id=$row[mem_id]&info=delete_member'><i class='fas fa-trash-alt'></i></a></td>";
}
}else{
echo "<div class='alert alert-warning'><b>0 result</b></div>";
}
}
?>