This repository was archived by the owner on Feb 2, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathadmin.php
More file actions
executable file
·253 lines (247 loc) · 10.8 KB
/
admin.php
File metadata and controls
executable file
·253 lines (247 loc) · 10.8 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
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
<?php include("header_admin.php");
include("admin_check.php");
include("db.php");
if(!$admin=1) {
die("<script>window.location = 'https://www.youtube.com/watch?v=dQw4w9WgXcQ'</script>"); // ASGYHAHHAHAH FUNNY NSAFYNFN FYNNY YOOO FMAIY GUY FINNY MEOMTNS
}?>
<h1>Welcome, <?php echo $_SESSION["username"];?></h1>
<pre>
<strong>PHP Version:</strong>
<?php echo phpversion();?> (<a href="phpinfo.php">info</a>) <?php echo "\n";?>
<strong>Uptime:</strong>
<?php system("uptime"); ?>
<strong>System Information:</strong>
<?php system("uname -a"); ?>
</pre>
<h2>Ban user<h2>
<form action="ban.php" method="post" enctype="multipart/form-data">
<input type='text' name="user" placeholder="Username" id='textbox' style="width: 250px;" name='textbox'>
<input type='text' name="bannedUntil" placeholder="Ban until (UNIX date)" id='textbox' style="width: 250px;" name='textbox'>
<input type='text' name="banReason" placeholder="Ban reason")" id='textbox' style="width: 250px;" name='textbox'>
<input type="submit" value="Ban" name="submit">
</form>
<h2>Unban user<h2>
<form action="unban.php" method="post" enctype="multipart/form-data">
<input type='text' name="user" placeholder="Username" id='textbox' style="width: 250px;" name='textbox'>
<input type="submit" value="Unban" name="submit">
<h2>Videos</h2>
<h3>Unapproved</h3>
<!-- begin recently featured -->
<table class="roundedTable" width="auto" align="center" cellpadding="0" cellspacing="0" border="0" bgcolor="#cccccc">
<tr>
<td><img src="img/box_login_tl.gif" width="5" height="5"></td>
<td width="100%"><img src="img/pixel.gif" width="1" height="5"></td>
<td><img src="img/box_login_tr.gif" width="5" height="5"></td>
</tr>
<tr>
<td><img src="img/pixel.gif" width="5" height="1"></td>
<td width="585">
<div class="sunkenTitleBar">
<div class="moduleTitle">
<span style="color:#444;">Unapproved Videos</span>
</div>
</div>
<div class="list-view">
<?php
$sql = mysqli_query($connect, "SELECT * FROM videodb WHERE `isApproved` = '0'"); //instructions for sql
while ($fetch = mysqli_fetch_assoc($sql)) { //go forward with instructions
$idvideolist = $fetch['VideoID'];
$lengthlist = 0;
if($fetch['VideoLength'] > 3600) {
$lengthlist = floor($fetch['VideoLength'] / 3600) . ":" . gmdate("i:s", $fetch['VideoLength'] % 3600);
} else {
$lengthlist = gmdate("i:s", $fetch['VideoLength'] % 3600) ;
};
$namevideolist = htmlspecialchars($fetch['VideoName']);
$uploadervideolist = htmlspecialchars($fetch['Uploader']); // get recommendations information
$uploadvideolist = htmlspecialchars($fetch['UploadDate']); // get recommendations information
$descvideolist = htmlspecialchars($fetch['VideoDesc']);
$viewsvideolist = htmlspecialchars($fetch['ViewCount']);
echo "<div class='moduleEntry'>
<div class='video-entry' style='padding: 0;'>
<div class='v120WideEntry'>
<div class='v120WrapperOuter'>
<div class='v120WrapperInner'>
<a id='video-url-muP9eH2p2PI' href='watch.php?v=$idvideolist' rel='nofollow'><img title='$namevideolist' src='content/thumbs/".$idvideolist.".png' onerror=\"this.src='img/default.png'\" class='vimg120' qlicon='muP9eH2p2PI' alt='$namevideolist'></a>
<div class='video-time'><span id='video-run-time-muP9eH2p2PI'>$lengthlist</span></div>
</div>
</div>
</div>
<div class='video-main-content' id='video-main-content-muP9eH2p2PI'>
<div class='video-title '>
<div class='video-long-title'>
<a id='video-long-title-muP9eH2p2PI' href='watch.php?v=$idvideolist&player=0' title='$namevideolist' rel='nofollow'>$namevideolist</a>
</div>
</div>
<div id='video-description-muP9eH2p2PI' class='video-description'>
$descvideolist
</div>
<div class='video-facets'>
Uploaded on $uploadvideolist by: <span class='video-username'><a id='video-from-username-muP9eH2p2PI' class='hLink' href='profile.php?user=$uploadervideolist'>$uploadervideolist</a></span>
</div>
<div class='video-facets'>
<a href='approve.php?v=$idvideolist'>approve</a></span> - <a href='delete.php?v=$idvideolist'>decline</a></span>
</div>
</div>
<div class='video-clear-list-left'></div>
</div>
</div>";
}
?>
</td>
<td><img src="img/pixel.gif" width="5" height="1"></td>
</tr>
<tr>
<td><img src="img/box_login_bl.gif" width="5" height="5"></td>
<td><img src="img/pixel.gif" width="1" height="5"></td>
<td><img src="img/box_login_br.gif" width="5" height="5"></td>
</tr>
</table>
<!-- end recently featured -->
<h3>Approved</h3>
<!-- begin recently featured -->
<table class="roundedTable" width="auto" align="center" cellpadding="0" cellspacing="0" border="0" bgcolor="#cccccc">
<tr>
<td><img src="img/box_login_tl.gif" width="5" height="5"></td>
<td width="100%"><img src="img/pixel.gif" width="1" height="5"></td>
<td><img src="img/box_login_tr.gif" width="5" height="5"></td>
</tr>
<tr>
<td><img src="img/pixel.gif" width="5" height="1"></td>
<td width="585">
<div class="sunkenTitleBar">
<div class="moduleTitle">
<span style="color:#444;">Approved Videos</span>
</div>
</div>
<div class="list-view">
<?php
$sql = mysqli_query($connect, "SELECT * FROM videodb WHERE `isApproved` = '1'"); //instructions for sql
while ($fetch = mysqli_fetch_assoc($sql)) { //go forward with instructions
$idvideolist = $fetch['VideoID'];
$lengthlist = 0;
if($fetch['VideoLength'] > 3600) {
$lengthlist = floor($fetch['VideoLength'] / 3600) . ":" . gmdate("i:s", $fetch['VideoLength'] % 3600);
} else {
$lengthlist = gmdate("i:s", $fetch['VideoLength'] % 3600) ;
};
$namevideolist = htmlspecialchars($fetch['VideoName']);
$uploadervideolist = htmlspecialchars($fetch['Uploader']); // get recommendations information
$uploadvideolist = htmlspecialchars($fetch['UploadDate']); // get recommendations information
$descvideolist = htmlspecialchars($fetch['VideoDesc']);
$viewsvideolist = htmlspecialchars($fetch['ViewCount']);
echo "<div class='moduleEntry'>
<div class='video-entry' style='padding: 0;'>
<div class='v120WideEntry'>
<div class='v120WrapperOuter'>
<div class='v120WrapperInner'>
<a id='video-url-muP9eH2p2PI' href='watch.php?v=$idvideolist' rel='nofollow'><img title='$namevideolist' src='content/thumbs/".$idvideolist.".png' onerror=\"this.src='img/default.png'\" class='vimg120' qlicon='muP9eH2p2PI' alt='$namevideolist'></a>
<div class='video-time'><span id='video-run-time-muP9eH2p2PI'>$lengthlist</span></div>
</div>
</div>
</div>
<div class='video-main-content' id='video-main-content-muP9eH2p2PI'>
<div class='video-title '>
<div class='video-long-title'>
<a id='video-long-title-muP9eH2p2PI' href='watch.php?v=$idvideolist&player=0' title='$namevideolist' rel='nofollow'>$namevideolist</a>
</div>
</div>
<div id='video-description-muP9eH2p2PI' class='video-description'>
$descvideolist
</div>
<div class='video-facets'>
Uploaded on $uploadvideolist by: <span class='video-username'><a id='video-from-username-muP9eH2p2PI' class='hLink' href='profile.php?user=$uploadervideolist'>$uploadervideolist</a></span>
</div>
<div class='video-facets'>
<a href='unapprove.php?v=$idvideolist'>unapprove</a></span>
</div>
</div>
<div class='video-clear-list-left'></div>
</div>
</div>";
}
?>
</td>
<td><img src="img/pixel.gif" width="5" height="1"></td>
</tr>
<tr>
<td><img src="img/box_login_bl.gif" width="5" height="5"></td>
<td><img src="img/pixel.gif" width="1" height="5"></td>
<td><img src="img/box_login_br.gif" width="5" height="5"></td>
</tr>
</table>
<!-- end recently featured -->
<h3>Declined</h3>
<!-- begin recently featured -->
<table class="roundedTable" width="auto" align="center" cellpadding="0" cellspacing="0" border="0" bgcolor="#cccccc">
<tr>
<td><img src="img/box_login_tl.gif" width="5" height="5"></td>
<td width="100%"><img src="img/pixel.gif" width="1" height="5"></td>
<td><img src="img/box_login_tr.gif" width="5" height="5"></td>
</tr>
<tr>
<td><img src="img/pixel.gif" width="5" height="1"></td>
<td width="585">
<div class="sunkenTitleBar">
<div class="moduleTitle">
<span style="color:#444;">Declined Videos</span>
</div>
</div>
<div class="list-view">
<?php
$sql = mysqli_query($connect, "SELECT * FROM videodb WHERE `isApproved` = '2'"); //instructions for sql
while ($fetch = mysqli_fetch_assoc($sql)) { //go forward with instructions
$idvideolist = $fetch['VideoID'];
$lengthlist = 0;
if($fetch['VideoLength'] > 3600) {
$lengthlist = floor($fetch['VideoLength'] / 3600) . ":" . gmdate("i:s", $fetch['VideoLength'] % 3600);
} else {
$lengthlist = gmdate("i:s", $fetch['VideoLength'] % 3600) ;
};
$namevideolist = htmlspecialchars($fetch['VideoName']);
$uploadervideolist = htmlspecialchars($fetch['Uploader']); // get recommendations information
$uploadvideolist = htmlspecialchars($fetch['UploadDate']); // get recommendations information
$descvideolist = htmlspecialchars($fetch['VideoDesc']);
$viewsvideolist = htmlspecialchars($fetch['ViewCount']);
echo "<div class='moduleEntry'>
<div class='video-entry' style='padding: 0;'>
<div class='v120WideEntry'>
<div class='v120WrapperOuter'>
<div class='v120WrapperInner'>
<a id='video-url-muP9eH2p2PI' href='watch.php?v=$idvideolist' rel='nofollow'><img title='$namevideolist' src='content/thumbs/".$idvideolist.".png' onerror=\"this.src='img/default.png'\" class='vimg120' qlicon='muP9eH2p2PI' alt='$namevideolist'></a>
<div class='video-time'><span id='video-run-time-muP9eH2p2PI'>$lengthlist</span></div>
</div>
</div>
</div>
<div class='video-main-content' id='video-main-content-muP9eH2p2PI'>
<div class='video-title '>
<div class='video-long-title'>
<a id='video-long-title-muP9eH2p2PI' href='watch.php?v=$idvideolist&player=0' title='$namevideolist' rel='nofollow'>$namevideolist</a>
</div>
</div>
<div id='video-description-muP9eH2p2PI' class='video-description'>
$descvideolist
</div>
<div class='video-facets'>
Uploaded on $uploadvideolist by: <span class='video-username'><a id='video-from-username-muP9eH2p2PI' class='hLink' href='profile.php?user=$uploadervideolist'>$uploadervideolist</a></span>
</div>
</div>
<div class='video-clear-list-left'></div>
</div>
</div>";
}
?>
</td>
<td><img src="img/pixel.gif" width="5" height="1"></td>
</tr>
<tr>
<td><img src="img/box_login_bl.gif" width="5" height="5"></td>
<td><img src="img/pixel.gif" width="1" height="5"></td>
<td><img src="img/box_login_br.gif" width="5" height="5"></td>
</tr>
</table>
</div>
</div>
<!-- end recently featured -->
</body>
</html>