From: moodler Date: Tue, 12 Nov 2002 03:02:51 +0000 (+0000) Subject: For very large classes don't even try to show all the participants X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=cbb0fee071e8eadf2a7aa399f6a2029ad39d49c7;p=moodle.git For very large classes don't even try to show all the participants --- diff --git a/user/index.php b/user/index.php index c2126892ed..8f6b1131e1 100644 --- a/user/index.php +++ b/user/index.php @@ -68,6 +68,9 @@ foreach ($students as $student) { print_user($student, $course, $string); } + } else if ($numstudents > $USER_HUGE_CLASS) { + print_heading(get_string("toomanytoshow")); + } else { // Print one big table with abbreviated info $columns = array("name", "city", "country", "lastaccess"); diff --git a/user/lib.php b/user/lib.php index b867fc9429..f8e0279047 100644 --- a/user/lib.php +++ b/user/lib.php @@ -2,6 +2,7 @@ $USER_SMALL_CLASS = 20; // Below this is considered small $USER_LARGE_CLASS = 200; // Above this is considered large +$USER_HUGE_CLASS = 500; // Above this is considered too many to display /// FUNCTIONS ///////////////////////////////////////////////////////////