Repository navigation
Expand file tree
/
Copy pathadminusers.php
More file actions
137 lines (134 loc) · 6.18 KB
/
Copy pathadminusers.php
File metadata and controls
137 lines (134 loc) · 6.18 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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
<?php
include ('database/databaseCon.php');
?>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="styles/css/adminusers.css">
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Admin - Users</title>
</head>
<body>
<div class="container">
<div class="nav">
<ul>
<li>
<a href="#">
<span class="icon"></span>
<span class="title">VISIONARY</span>
</a>
</li>
<li>
<a href="admindashboard.php">
<span class="icon"><ion-icon name="home-outline"></ion-icon></span>
<span class="title">Dashboard</span>
</a>
</li>
<li style="background-color: #fff;">
<a href="adminusers.php" style="color: #2a2185;font-weight: bold;">
<span class="icon"><ion-icon name="person-outline"></ion-icon></span>
<span class="title">Users</span>
</a>
</li>
<li>
<a href="adminmeetings.php">
<span class="icon"><ion-icon name="people-outline"></ion-icon></span>
<span class="title">Meetings</span>
</a>
</li>
<li>
<a href="admincomplains.php">
<span class="icon"><ion-icon name="chatbox-ellipses-outline"></ion-icon></span>
<span class="title">Complains</span>
</a>
</li>
<li>
<a href="admininventry.php">
<span class="icon"><ion-icon name="bag-outline"></ion-icon></span>
<span class="title">Inventory</span>
</a>
</li>
<li>
<a href="adminroom.php">
<span class="icon"><ion-icon name="library-outline"></ion-icon></span>
<span class="title">Meeting Rooms</span>
</a>
</li>
<li>
<a href="adminparking.php">
<span class="icon"><ion-icon name="car-outline"></ion-icon></span>
<span class="title">Manage Parking</span>
</a>
</li>
<li>
<a href="adminhealth.php">
<span class="icon"><ion-icon name="medkit-outline"></ion-icon></span>
<span class="title">Health Screening</span>
</a>
</li>
</ul>
</div>
</div>
<div class="main">
<div class="topbar">
<div class="toggle">
<ion-icon name="logo-vimeo" style="color: #2a2185;"></ion-icon>
</div>
<div class="search"></div>
<div class="user"><a href="admindashboard.php"><ion-icon name="home-outline" style="color: green;"></ion-icon></a></div>
</div>
<div class="add">
<a href="addNewUser.php"><button>Add User</button></a>
</div>
<div class="table">
<table>
<thead>
<th>ID</th>
<th>First Name</th>
<th>Last Name</th>
<th>Email</th>
<th>Contact</th>
<th>Role</th>
<th>Password</th>
<th>Action</th>
</thead>
<tbody>
<?php
$sql = "SELECT * FROM new_users";
$result = mysqli_query($con,$sql);
if($result)
{
while($row = mysqli_fetch_assoc($result))
{
$id = $row['id'];
$firstname = $row['firstname'];
$lastname = $row['lastname'];
$email = $row['email'];
$contact = $row['contact'];
$password = $row['password'];
$role = $row['role'];
echo '<tr>
<td data-label="ID">'.$id.'</td>
<td data-label="First Name">'.$firstname.'</td>
<td data-label="Last Name">'.$lastname.'</td>
<td data-label="Email">'.$email.'</td>
<td data-label="Contact">'.$contact.'</td>
<td data-label="Role">'.$role.'</td>
<td data-label="Password">'.$password.'</td>
<td data-label="Action"><a href="edit.php?upid='.$id.'"><button class="edit">Edit</button></a> <a href="delete.php?delID='.$id.'"><button class="delete">Delete</button></a></td>
</tr>';
}
}
?>
</tbody>
</table>
</div>
</div>
<script>
</script>
<script type="module" src="https://unpkg.com/ionicons@5.5.2/dist/ionicons/ionicons.esm.js"></script>
<script nomodule src="https://unpkg.com/ionicons@5.5.2/dist/ionicons/ionicons.js"></script>
</body>
</html>