]> git.mjollnir.org Git - moodle.git/commitdiff
Improvements to display of users
authormoodler <moodler>
Fri, 21 Mar 2003 10:08:23 +0000 (10:08 +0000)
committermoodler <moodler>
Fri, 21 Mar 2003 10:08:23 +0000 (10:08 +0000)
admin/user.php

index ece6fd7439ade60485b8c69bbff0391ec2a71cba..82a4acf30a6bc68ada30e9ce799537f0eeae43bd 100644 (file)
 
         // Carry on with the user listing
 
-        $usertotalcount = get_users_count();
 
         $columns = array("name", "email", "city", "country", "lastaccess");
 
         }
 
         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));
             }
         }
 
-        $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;