From: moodler Date: Thu, 13 May 2004 03:09:47 +0000 (+0000) Subject: Some fixes for confirmation emails on sites with long names X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=58d2472072de810c170d9418bcdbd8af2c541787;p=moodle.git Some fixes for confirmation emails on sites with long names - include a HTML version of the email - wrap all text emails at 79 characters now, not 70 I think quoting of text based emails on 80-character terminals would be pretty rare these days --- diff --git a/lib/moodlelib.php b/lib/moodlelib.php index 5fafa85170..e9862593b7 100644 --- a/lib/moodlelib.php +++ b/lib/moodlelib.php @@ -1281,7 +1281,7 @@ function email_to_user($user, $from, $subject, $messagetext, $messagehtml="", $a $mail->AddAddress("$user->email", fullname($user) ); - $mail->WordWrap = 70; // set word wrap + $mail->WordWrap = 79; // set word wrap if (!empty($from->precedence)) { $mail->Precedence = $from->precedence; // set precedence level eg "bulk" "list" or "junk" @@ -1361,7 +1361,9 @@ function send_confirmation_email($user) { $message = get_string("emailconfirmation", "", $data); $subject = get_string("emailconfirmationsubject", "", $site->fullname); - return email_to_user($user, $from, $subject, $message); + $messagehtml = text_to_html($message, false, false, true); + + return email_to_user($user, $from, $subject, $message, $messagehtml); }