forked from extern/egroupware
* notification: if sending meeting requests: only send the text/plain part, as outlook interprets the html part as meeting description
This commit is contained in:
parent
06ae9da6e1
commit
94b69703e4
@ -97,15 +97,25 @@ class notifications_email implements notifications_iface {
|
||||
$this->mail->FromName = $this->sender->account_fullname;
|
||||
$this->mail->Subject = $_subject;
|
||||
//error_log(__METHOD__.__LINE__.array2string($_attachments));
|
||||
$isMeetingRequestNotif = false;
|
||||
if ($_attachments && stripos($_attachments[0]->type,"text/calendar; method=")!==false)
|
||||
{
|
||||
$this->mail->AltExtended = $_attachments[0]->string;
|
||||
$this->mail->AltExtendedContentType = $_attachments[0]->type;
|
||||
unset($_attachments[0]);
|
||||
$isMeetingRequestNotif = true;
|
||||
}
|
||||
$this->mail->IsHTML(true);
|
||||
// do not send html part if this is a meeting request notification
|
||||
$this->mail->IsHTML(($isMeetingRequestNotif?false:true));
|
||||
if ($isMeetingRequestNotif===false)
|
||||
{
|
||||
$this->mail->Body = $body_html;
|
||||
$this->mail->AltBody = $body_plain;
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->mail->Body = $body_plain;
|
||||
}
|
||||
if(is_array($_attachments) && count($_attachments) > 0)
|
||||
{
|
||||
foreach($_attachments as $attachment)
|
||||
|
Loading…
Reference in New Issue
Block a user