-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathadmin_approve.php
More file actions
191 lines (154 loc) · 8.29 KB
/
admin_approve.php
File metadata and controls
191 lines (154 loc) · 8.29 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
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
<?php
session_start();
include "connection.php";
$res19=mysqli_query($link,"select username from admin_register where username='$_SESSION[username]'");
$count19=mysqli_num_rows($res19);
if(!isset($_SESSION["username"]) || ($count19==0)){
?>
<script type="text/javascript">
window.location="admin_login.php";
</script>
<?php
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<!-- Meta, title, CSS, favicons, etc. -->
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Student Beneficiary System | SBS </title>
<link href="css/bootstrap.min.css" rel="stylesheet">
<link href="css/font-awesome.min.css" rel="stylesheet">
<link href="css/nprogress.css" rel="stylesheet">
<link href="css/custom.min.css" rel="stylesheet">
</head>
<body class="nav-md">
<div class="container body">
<div class="main_container">
<div class="col-md-3 left_col">
<div class="left_col scroll-view">
<div class="navbar nav_title" style="border: 0;">
<a href="#" class="site_title"><i class="fa fa-book"></i> <span>SBS</span></a>
</div>
<div class="clearfix"></div>
<!-- menu profile quick info -->
<div class="profile clearfix">
<div class="profile_info">
<span>Welcome,</span>
<h2><?php echo $_SESSION["username"];?></h2>
</div>
<div class="clearfix"></div>
</div>
<!-- /menu profile quick info -->
<br/>
<!-- sidebar menu -->
<div id="sidebar-menu" class="main_menu_side hidden-print main_menu">
<div class="menu_section">
<h3>General</h3>
<ul class="nav side-menu">
<li><a href="ahome.php"><i class="fa fa-home"></i> Home <span class="fa fa-chevron"></span></a>
</li>
<li><a href="aabout_us.php"><i class="fa fa-info-circle"></i> About Us <span class="fa fa-chevron"></span></a>
</li>
<li><a href="acontact.php"><i class="fa fa-mobile-phone"></i> Contact <span class="fa fa-chevron"></span></a>
</li>
<li><a href='courselist.php'><i class="fa fa-file"></i> Courses list <span class="fa fa-chevron"></span></a>
</li>
<li><a href='student_approve.php'><i class="fa fa-check-square"></i> Approve/Disapprove Student <span class="fa fa-chevron"></span></a>
</li>
<li><a href='bookslist.php'><i class="fa fa-book"></i> Books list <span class="fa fa-chevron"></span></a>
</li>
<li><a href='transactionlist.php'><i class="fa fa-exchange"></i> Transactions list <span class="fa fa-chevron"></span></a>
</li>
<li><a href='studentlist.php'><i class="fa fa-child"></i> Students list <span class="fa fa-chevron"></span></a>
</li>
<li><a href='adminlist.php'><i class="fa fa-user"></i> Admins list <span class="fa fa-chevron"></span></a>
</li>
<li><a href='adminreport.php'><i class="fa fa-bar-chart"></i> Analysis Report <span class="fa fa-chevron"></span></a>
</li>
<li><a href='achangepassword.php'><i class="fa fa-key"></i> Change Password <span class="fa fa-chevron"></span></a></li>
</ul>
</div>
</div>
</div>
</div>
<!-- top navigation -->
<div class="top_nav">
<div class="nav_menu">
<nav>
<div class="nav toggle">
<a id="menu_toggle"><i class="fa fa-bars"></i></a>
</div>
<ul class="nav navbar-nav navbar-right">
<li class="">
<a href="javascript:;" class="user-profile dropdown-toggle" data-toggle="dropdown"
aria-expanded="false">
<?php $res2=mysqli_query($link,"select fname,lname from admin where username='$_SESSION[username]'"); $row2=mysqli_fetch_array($res2); echo $row2["fname"]." ".$row2["lname"];?>
<span class=" fa fa-angle-down"></span>
</a>
<ul class="dropdown-menu dropdown-usermenu pull-right">
<li><a href="logout.php"><i class="fa fa-sign-out pull-right"></i> Log Out</a></li>
</ul>
</li>
</ul>
</nav>
</div>
</div>
<!-- /top navigation -->
<!-- page content area main -->
<div class="right_col" role="main">
<div class="">
<div class="page-title">
<div class="title_left">
<h3>Admin Details</h3>
</div>
</div>
<div class="clearfix"></div>
<div class="row" style="min-height:500px">
<div class="col-md-12 col-sm-12 col-xs-12">
<div class="x_panel">
<div class="x_title">
<h2>Verify Admin Details</h2>
<div class="clearfix"></div>
</div>
<div class="x_content">
<?php
$res=mysqli_query($link,"select * from admin_register");
echo "<table class='table table-bordered'>";
echo "<tr>";
echo "<th>"; echo "username"; echo "</th>";
echo "<th>"; echo "email"; echo "</th>";
echo "<th>"; echo "phoneno"; echo "</th>";
echo "<th>"; echo "Approval"; echo "</th>";
echo "<th>"; echo "Approve/Not approve"; echo "</th>";
echo "</tr>";
while($row=mysqli_fetch_array($res))
{
echo "<tr>";
echo "<td>"; echo $row["username"]; echo "</td>";
echo "<td>"; echo $row["email"]; echo "</td>";
echo "<td>"; echo $row["phoneno"]; echo "</td>";
echo "<td>"; echo $row["approval"]; echo "</td>";
if("$row[approval]"==0){
echo "<td>"; ?> <a href="a_approve.php?id=<?php echo $row["username"]; ?>">Approve</a> <?php echo "</td>";
}
else{
echo "<td>"; ?> <a href="a_notapprove.php?id=<?php echo $row["username"]; ?>">Not Approve</a> <?php echo "</td>";
}
echo "</tr>";
}
echo "</table>";
?>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- /page content -->
<?php
include "footer.php";
?>