From e550e2d694d81a8a011bb4eb6d49e71268e01770 Mon Sep 17 00:00:00 2001 From: moodler Date: Mon, 25 Aug 2003 17:53:47 +0000 Subject: [PATCH] Students now see a Change Password link under admin. Guests see *nothing* now --- course/lib.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/course/lib.php b/course/lib.php index 4de5e7c162..38e04576d4 100644 --- a/course/lib.php +++ b/course/lib.php @@ -828,11 +828,19 @@ function print_course_admin_links($course, $width=180) { $adminicon[]="\"\""; } - } else { // Students menu + } else if (!isguest()) { // Students menu if ($course->showgrades) { $admindata[]="id\">".get_string("grades")."..."; $adminicon[]="\"\""; } + if ($CFG->auth == "email" or $CFG->auth == "none" or $CFG->auth == "manual") { + $admindata[]="wwwroot/login/change_password.php?id=$course->id\">". + get_string("changepassword")."..."; + $adminicon[]="\"\""; + } else if ($CFG->changepassword) { + $admindata[]="changepassword\">".get_string("changepassword")."..."; + $adminicon[]="\"\""; + } } if (!empty($admindata)) { -- 2.39.5