Marijn button #99
@@ -1,6 +1,6 @@
|
||||
.admin-panel {
|
||||
margin: auto;
|
||||
/*min-width: 800px;*/
|
||||
min-width: 800px;
|
||||
}
|
||||
|
||||
.admin-title {
|
||||
@@ -36,8 +36,8 @@
|
||||
display: inline-block;
|
||||
margin: 10px;
|
||||
vertical-align: top;
|
||||
margin-left: 20px;
|
||||
margin-right: 20px;
|
||||
margin-right: 50px;
|
||||
margin-left: 50px;
|
||||
}
|
||||
|
||||
.admin-users {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Admin Panel</title>
|
||||
<script type="text/javascript">
|
||||
@@ -14,39 +14,80 @@
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div class="content">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<!-- function test_input taken from http://www.w3schools.com/php/php_form_validation.asp -->
|
||||
<?php
|
||||
$search = $pagetype = "";
|
||||
$status = array();
|
||||
|
||||
if ($_SERVER["REQUEST_METHOD"] == "POST") {
|
||||
$search = test_input($_POST["search"]);
|
||||
|
||||
if (!empty($_POST["pagetype"])) {
|
||||
$pagetype = test_input($_POST["pagetype"]);
|
||||
}
|
||||
|
||||
if (!empty($_POST["status"])) {
|
||||
$status = $_POST["status"];
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function test_input($data) {
|
||||
$data = trim($data);
|
||||
$data = stripslashes($data);
|
||||
$data = htmlspecialchars($data);
|
||||
return $data;
|
||||
}
|
||||
?>
|
||||
|
||||
<div class="content">
|
||||
<div class="platform admin-panel">
|
||||
<div class="admin-title">
|
||||
<h1>User Management Panel</h1>
|
||||
</div> <br>
|
||||
<form class="admin-actionform" action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>" method="post">
|
||||
<form class="admin-actionform"
|
||||
action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>"
|
||||
method="post">
|
||||
<div class="admin-options">
|
||||
<form class="admin-searchform" action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>" method="post">
|
||||
<form class="admin-searchform"
|
||||
action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>"
|
||||
method="post">
|
||||
<div class="admin-searchbar">
|
||||
<h2>Search</h2>
|
||||
<input type="text" name="search" class="admin-searchinput"> <br>
|
||||
<input type="text"
|
||||
name="search"
|
||||
class="admin-searchinput"
|
||||
value="<?php echo $search;?>"> <br>
|
||||
<input type="submit" value="Search">
|
||||
</div>
|
||||
<div class="admin-filter">
|
||||
<h2>Show:</h2>
|
||||
<input type="checkbox" name="status" id="normal" value="normal">
|
||||
<input type="checkbox" name="status[]" id="normal" value="normal"
|
||||
<?php if (in_array("normal", $status)) echo "checked";?>>
|
||||
<label for="normal">Normal</label><br>
|
||||
<input type="checkbox" name="status" id="frozen" value="frozen">
|
||||
<input type="checkbox" name="status[]" id="frozen" value="frozen"
|
||||
<?php if (in_array("frozen", $status)) echo "checked";?>>
|
||||
<label for="frozen">Frozen</label><br>
|
||||
<input type="checkbox" name="status" id="banned" value="banned">
|
||||
<input type="checkbox" name="status[]" id="banned" value="banned"
|
||||
<?php if (in_array("banned", $status)) echo "checked";?>>
|
||||
<label for="banned">Banned</label><br>
|
||||
<input type="checkbox" name="status" id="admin" value="admin">
|
||||
<input type="checkbox" name="status[]" id="admin" value="admin"
|
||||
<?php if (in_array("admin", $status)) echo "checked";?>>
|
||||
<label for="admin">Admin</label><br>
|
||||
<input type="checkbox" name="status" id="unvalidated" value="unvalidated">
|
||||
<input type="checkbox" name="status[]" id="unvalidated" value="unvalidated"
|
||||
<?php if (in_array("unvalidated", $status)) echo "checked";?>>
|
||||
<label for="unvalidated">Unvalidated</label>
|
||||
</div>
|
||||
<div class="admin-filtertype">
|
||||
<h2>Page Type:</h2>
|
||||
<input type="radio" name="type" id="user" value="user">
|
||||
<input type="radio" name="pagetype" id="user" value="user"
|
||||
<?php if (isset($pagetype) && $pagetype=="user") echo "checked";?>>
|
||||
<label for="user">Users</label><br>
|
||||
<input type="radio" name="type" id="group" value="group">
|
||||
<input type="radio" name="pagetype" id="group" value="group"
|
||||
<?php if (isset($pagetype) && $pagetype=="group") echo "checked";?>>
|
||||
<label for="group">Groups</label>
|
||||
</div>
|
||||
</form>
|
||||
@@ -56,7 +97,7 @@
|
||||
<label for="freeze">Freeze</label><br>
|
||||
<input type="radio" name="actions" id="ban" value="ban">
|
||||
<label for="ban">Ban</label><br>
|
||||
<input type="radio" name="actions" id="restore" value="unban">
|
||||
<input type="radio" name="actions" id="restore" value="restore">
|
||||
<label for="restore">Restore</label><br><br>
|
||||
<input type="submit" value="Confirm">
|
||||
</div>
|
||||
@@ -80,7 +121,9 @@
|
||||
<td>Banned</td>
|
||||
<td>unregulated time travel</td>
|
||||
<td>
|
||||
<form class="admin-useraction" action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>" method="post">
|
||||
<form class="admin-useraction"
|
||||
action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>"
|
||||
method="post">
|
||||
<select class="action" name="actions">
|
||||
<option value="freeze">Freeze</option>
|
||||
<option value="ban">Ban</option>
|
||||
@@ -96,7 +139,9 @@
|
||||
<td>Banned</td>
|
||||
<td>l33t h4xx</td>
|
||||
<td>
|
||||
<form class="admin-useraction" action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>" method="post">
|
||||
<form class="admin-useraction"
|
||||
action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>"
|
||||
method="post">
|
||||
<select class="action" name="actions">
|
||||
<option value="freeze">Freeze</option>
|
||||
<option value="ban">Ban</option>
|
||||
@@ -110,6 +155,6 @@
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user