Skip to content
Snippets Groups Projects
Commit 2926060f authored by Dries Buytaert's avatar Dries Buytaert
Browse files

- fixed small glitch in account listings

parent 02e28d29
No related branches found
No related tags found
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
......@@ -221,23 +221,16 @@ function account_view($name) {
}
function account_query($type = "") {
$queries = array(0 => array("users recently visiting", "ORDER BY last_access DESC"), 1 => array("users recently joining", "ORDER BY id DESC"), 2 => array("users with access rights", "WHERE access != '' ORDER BY last_access DESC"), 3 => array("users with pending accounts", "WHERE status = 1 ORDER BY last_access DESC"), 4 => array("users with blocked accounts", "WHERE status = 0 ORDER BY last_access DESC"));
$queries = array(array("users recently visiting", "ORDER BY last_access DESC"), array("users recently joining", "ORDER BY id DESC"), array("users with access rights", "WHERE access != '' ORDER BY last_access DESC"), array("users with pending accounts", "WHERE status = 1 ORDER BY last_access DESC"), array("users with blocked accounts", "WHERE status = 0 ORDER BY last_access DESC"));
return ($queries[$type] ? $queries[$type] : $queries);
}
function account_listing() {
foreach (account_query() as $key=>$array) {
$output .= "<LI><A HREF=\"admin.php?mod=account&type=$key\">$array[0]</A></LI>\n";
}
return "<OL>$output</OL>\n";
}
function account_admin() {
global $op, $edit, $id, $mod, $keys, $order, $name, $type;
print "<SMALL><A HREF=\"admin.php?mod=account&op=access\">access control</A> | <A HREF=\"admin.php?mod=account&op=listing\">account listings</A> | <A HREF=\"admin.php?mod=account&op=search\">search account</A> | <A HREF=\"admin.php?mod=account\">overview</A> | <A HREF=\"admin.php?mod=account&op=help\">help</A></SMALL><HR>";
$type = ($type ? $type : 1);
$type = ($type ? $type : 0);
switch ($op) {
case "access":
......@@ -268,7 +261,7 @@ function account_admin() {
print account_help();
break;
case "listing":
print account_listing();
print node_listing(account_query());
break;
case "search":
print search_form($keys);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment