MDL-35966 Assignment - Localisation issue - use userdate not strftime
This is causing a database error (reported on MySQL) when strftime returns non-utf8 characters. This occurs when sending assignment notifications. This was reported and a solution provided by Chien Wen-Chang(簡文章).
This commit is contained in:
@@ -2483,7 +2483,7 @@ class assign {
|
||||
$info->username = fullname($userfrom, true);
|
||||
$info->assignment = format_string($assignmentname,true, array('context'=>$context));
|
||||
$info->url = $CFG->wwwroot.'/mod/assign/view.php?id='.$coursemodule->id;
|
||||
$info->timeupdated = strftime('%c',$updatetime);
|
||||
$info->timeupdated = userdate($updatetime, get_string('strftimerecentfull'));
|
||||
|
||||
$postsubject = get_string($messagetype . 'small', 'assign', $info);
|
||||
$posttext = self::format_notification_message_text($messagetype, $info, $course, $context, $modulename, $assignmentname);
|
||||
|
||||
Reference in New Issue
Block a user