From 181b888e160b38f3a14474bc2a9b77b836e4d0d6 Mon Sep 17 00:00:00 2001 From: gustav_delius Date: Sun, 16 Jan 2005 17:27:40 +0000 Subject: [PATCH] ugly hack to fix bug 1824 about wrong fullname format in log info. --- course/lib.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/course/lib.php b/course/lib.php index 8a055bf85b..36d4ce5267 100644 --- a/course/lib.php +++ b/course/lib.php @@ -607,7 +607,12 @@ function print_log($course, $user=0, $date=0, $order="l.time ASC", $page=0, $per $ldcache[$log->module][$log->action] = $ld; } if ($ld && !empty($log->info)) { - $log->info = get_field($ld->mtable, $ld->field, 'id', $log->info); + // ugly hack to make sure fullname is shown correctly + if (($ld->mtable == 'user') and ($ld->field == 'CONCAT(firstname," ",lastname)')) { + $log->info = fullname(get_record($ld->mtable, 'id', $log->info), true); + } else { + $log->info = get_field($ld->mtable, $ld->field, 'id', $log->info); + } } $log->url = strip_tags(urldecode($log->url)); // Some XSS protection -- 2.39.5