add javascript for userlist tablehead checkall box, fix pageselector css
This commit is contained in:
@@ -52,10 +52,16 @@
|
|||||||
margin: 10px;
|
margin: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.admin-userpage {
|
.admin-userheading {
|
||||||
width: 170px;
|
width: auto;
|
||||||
margin-bottom: 20px;
|
float: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.admin-pageui {
|
||||||
|
text-align: right;
|
||||||
float: right;
|
float: right;
|
||||||
|
width: auto;
|
||||||
|
margin-bottom: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.usertitle {
|
.usertitle {
|
||||||
|
|||||||
@@ -30,8 +30,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
document.write(checked);
|
|
||||||
allbox.checked = checked;
|
allbox.checked = checked;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -221,39 +219,45 @@ function test_input($data) {
|
|||||||
<br>
|
<br>
|
||||||
|
|
||||||
<div class="admin-users">
|
<div class="admin-users">
|
||||||
<h2 class="usertitle">Users:</h2>
|
<div class="admin-usertitle">
|
||||||
|
<div class="admin-userheading">
|
||||||
<div class="admin-userpage">
|
<h2>Users:</h2>
|
||||||
<p class="pagenumber">Showing results
|
</div>
|
||||||
<?php
|
<div class="admin-pageui">
|
||||||
if ($pagetype == "user") {
|
<?php
|
||||||
$pages = countSomeUsersByStatus($db, $search, $status);
|
if ($pagetype == "user") {
|
||||||
} else {
|
$pages = countSomeUsersByStatus($db, $search, $status);
|
||||||
$pages = countSomeGroupsByStatus($db, $search, $status);
|
} else {
|
||||||
}
|
$pages = countSomeGroupsByStatus($db, $search, $status);
|
||||||
$countresults = $pages->fetchColumn();
|
}
|
||||||
$mincount = min($listm, $countresults);
|
$countresults = $pages->fetchColumn();
|
||||||
echo "$listn to $mincount out of $countresults"; ?></p><br>
|
$mincount = min($listm, $countresults);
|
||||||
<input type="submit" name="prev" value="prev">
|
$minlist = min($listn + 1, $countresults);
|
||||||
<form class="admin-pageselector"
|
?>
|
||||||
action="<?php htmlspecialchars(basename($_SERVER['REQUEST_URI'])) ?>"
|
<p class="pagenumber">Current page:</p>
|
||||||
method="post">
|
<form class="admin-pageselector"
|
||||||
<select class="admin-pageselect"
|
action="<?php htmlspecialchars(basename($_SERVER['REQUEST_URI'])) ?>"
|
||||||
name="pageselect"
|
method="post">
|
||||||
onchange="this.form.submit()"
|
<select class="admin-pageselect"
|
||||||
value="">
|
name="pageselect"
|
||||||
<?php
|
onchange="this.form.submit()"
|
||||||
for ($i=1; $i <= ceil($countresults / $perpage); $i++) {
|
value="">
|
||||||
if ($currentpage == $i) {
|
<?php
|
||||||
echo "<option value='$i' selected>$i</option>";
|
for ($i=1; $i <= ceil($countresults / $perpage); $i++) {
|
||||||
} else {
|
if ($currentpage == $i) {
|
||||||
echo "<option value='$i'>$i</option>";
|
echo "<option value='$i' selected>$i</option>";
|
||||||
|
} else {
|
||||||
|
echo "<option value='$i'>$i</option>";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
?>
|
||||||
?>
|
</select>
|
||||||
</select>
|
</form>
|
||||||
</form>
|
<p class="entriesshown">
|
||||||
<input type="submit" name="next" value="next">
|
<?php
|
||||||
|
echo "Showing results $minlist to $mincount out of $countresults";
|
||||||
|
?>
|
||||||
|
</div>
|
||||||
</div> <br>
|
</div> <br>
|
||||||
|
|
||||||
<table class="usertable">
|
<table class="usertable">
|
||||||
@@ -281,6 +285,7 @@ function test_input($data) {
|
|||||||
$role = $user['role'];
|
$role = $user['role'];
|
||||||
$bancomment = $user['bancomment'];
|
$bancomment = $user['bancomment'];
|
||||||
$thispage = htmlspecialchars(basename($_SERVER['REQUEST_URI']));
|
$thispage = htmlspecialchars(basename($_SERVER['REQUEST_URI']));
|
||||||
|
$function = "checkCheckAll(document.getElementById('checkall'))";
|
||||||
|
|
||||||
echo("
|
echo("
|
||||||
<tr>
|
<tr>
|
||||||
@@ -289,7 +294,7 @@ function test_input($data) {
|
|||||||
class='checkbox-list'
|
class='checkbox-list'
|
||||||
value='$userID'
|
value='$userID'
|
||||||
form='admin-batchform'
|
form='admin-batchform'
|
||||||
onchange='checkCheckAll(document.getElementById('checkall'))'>
|
onchange=" . "$function" . ">
|
||||||
</td>
|
</td>
|
||||||
<td>$username</td>
|
<td>$username</td>
|
||||||
<td>$role</td>
|
<td>$role</td>
|
||||||
@@ -319,6 +324,7 @@ function test_input($data) {
|
|||||||
$role = $group['status'];
|
$role = $group['status'];
|
||||||
$description = $group['description'];
|
$description = $group['description'];
|
||||||
$thispage = htmlspecialchars(basename($_SERVER['REQUEST_URI']));
|
$thispage = htmlspecialchars(basename($_SERVER['REQUEST_URI']));
|
||||||
|
$function = "checkCheckAll(document.getElementById('checkall'))";
|
||||||
|
|
||||||
echo("
|
echo("
|
||||||
<tr>
|
<tr>
|
||||||
@@ -326,7 +332,8 @@ function test_input($data) {
|
|||||||
name='checkbox-group[]'
|
name='checkbox-group[]'
|
||||||
class='checkbox-list'
|
class='checkbox-list'
|
||||||
value='$groupID'
|
value='$groupID'
|
||||||
form='admin-groupbatchform'>
|
form='admin-groupbatchform'
|
||||||
|
onchange=" . "$function" . ">
|
||||||
</td>
|
</td>
|
||||||
<td>$name</td>
|
<td>$name</td>
|
||||||
<td>$role</td>
|
<td>$role</td>
|
||||||
|
|||||||
Reference in New Issue
Block a user