From 1e9b70a1c3f30f1943be19d84f6f93c776bcd0e1 Mon Sep 17 00:00:00 2001 From: lainme Date: Wed, 25 Mar 2015 16:51:10 +0800 Subject: [PATCH] fix no email content when plain email enabled --- lib.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib.php b/lib.php index db82aba..30be04c 100644 --- a/lib.php +++ b/lib.php @@ -207,7 +207,7 @@ function sendCancelMail($info){ $body = $apply_setting['cancelmailcontent']->value; $body = updateMailContent($body,$replace); $contact = get_admin(); - email_to_user($info, $contact, $apply_setting['cancelmailsubject']->value, '', $body); + email_to_user($info, $contact, $apply_setting['cancelmailsubject']->value, html_to_text($body), $body); } function sendConfirmMail($info){ @@ -219,7 +219,7 @@ function sendConfirmMail($info){ $body = $apply_setting['confirmmailcontent']->value; $body = updateMailContent($body,$replace); $contact = get_admin(); - email_to_user($info, $contact, $apply_setting['confirmmailsubject']->value, '', $body); + email_to_user($info, $contact, $apply_setting['confirmmailsubject']->value, html_to_text($body), $body); } function sendConfirmMailToTeachers($courseid,$instanceid,$desc){ @@ -242,7 +242,7 @@ function sendConfirmMailToTeachers($courseid,$instanceid,$desc){ $contact = get_admin(); $info = $editTeacher; $info->coursename = $course->fullname; - email_to_user($info, $contact, get_string('mailtoteacher_suject', 'enrol_apply'), '', $body); + email_to_user($info, $contact, get_string('mailtoteacher_suject', 'enrol_apply'), html_to_text($body), $body); } } } @@ -267,7 +267,7 @@ function sendConfirmMailToManagers($courseid,$desc){ $contact = get_admin(); $info = $userWithManagerRole; $info->coursename = $course->fullname; - email_to_user($info, $contact, get_string('mailtoteacher_suject', 'enrol_apply'), '', $body); + email_to_user($info, $contact, get_string('mailtoteacher_suject', 'enrol_apply'), html_to_text($body), $body); } } }