From f1603208db2ebdebd872f5b170f84fa49076c183 Mon Sep 17 00:00:00 2001 From: moodler Date: Mon, 27 Oct 2003 14:15:05 +0000 Subject: [PATCH] The last access date is now that of the course. --- user/view.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/user/view.php b/user/view.php index 91c9d7ecee..eda8489fba 100644 --- a/user/view.php +++ b/user/view.php @@ -22,10 +22,14 @@ require_login($course->id); } - $countries = get_list_of_countries(); - add_to_log($course->id, "user", "view", "view.php?id=$user->id&course=$course->id", "$user->id"); + if ($student = get_record("user_students", "userid", $user->id, "course", $course->id)) { + $user->lastaccess = $student->timeaccess; + } else if ($teacher = get_record("user_teachers", "userid", $user->id, "course", $course->id)) { + $user->lastaccess = $teacher->timeaccess; + } + $fullname = "$user->firstname $user->lastname"; $personalprofile = get_string("personalprofile"); $participants = get_string("participants"); @@ -92,6 +96,7 @@ echo "city or $user->country) { + $countries = get_list_of_countries(); print_row(get_string("location").":", "$user->city, ".$countries["$user->country"]); } -- 2.39.5