From: moodler Date: Fri, 21 Mar 2003 10:08:23 +0000 (+0000) Subject: Improvements to display of users X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=49e16355c2b79cdaabaa3929d8e776a9808e5c31;p=moodle.git Improvements to display of users --- diff --git a/admin/user.php b/admin/user.php index ece6fd7439..82a4acf30a 100644 --- a/admin/user.php +++ b/admin/user.php @@ -128,7 +128,6 @@ // Carry on with the user listing - $usertotalcount = get_users_count(); $columns = array("name", "email", "city", "country", "lastaccess"); @@ -152,7 +151,7 @@ } if (!$users = get_users_listing($sort, $dir, $page, $recordsperpage, $search)) { - if (!$users = get_users_listing($sort, $dir, $page, $recordsperpage)) { + if (!$users = get_users_listing($sort, $dir, 0, $recordsperpage)) { error("No users found!"); } else { notify(get_string("nousersmatching", "", $search)); @@ -160,8 +159,15 @@ } } - $usercount = count($users); - print_heading("$usercount/$usertotalcount ".get_string("users")); + $usercount = get_users_count(); + + if ($search) { + $usersearchcount = get_users_count($search); + print_heading("$usersearchcount / $usercount ".get_string("users")); + $usercount = $usersearchcount; + } else { + print_heading("$usercount ".get_string("users")); + } $a->start = $page; $a->end = $page + $recordsperpage;