X-Git-Url: http://git.roojs.org/?a=blobdiff_plain;f=Mailer.php;fp=Mailer.php;h=3868884384fe2311ff8f48c73138309f48623b9a;hb=d61a3580945f5e3acbee884d1ce43a336277b112;hp=c289c55f0b3b0eede6a6f91ac6ffa158b22d4a52;hpb=f380fe2e72dc1c4d33801df173eac49df259d938;p=Pman.Core diff --git a/Mailer.php b/Mailer.php index c289c55f..38688843 100644 --- a/Mailer.php +++ b/Mailer.php @@ -241,7 +241,9 @@ class Pman_Core_Mailer { unset($parts[1]['Content-Type']); } $mime->setTXTBody($parts[2]); + $this->textbody = $parts[2]; $mime->setHTMLBody($htmlbody); + // var_dump($mime);exit; foreach($this->images as $cid=>$cdata) { @@ -269,8 +271,10 @@ class Pman_Core_Mailer { if(preg_match('/text\/html/', $header['Content-Type'])){ $mime->setHTMLBody($parts[2]); $mime->setTXTBody('This message is in HTML only'); + $this->textbody = 'This message is in HTML only'; }else{ $mime->setTXTBody($parts[2]); + $this->textbody = $parts[2]; $mime->setHTMLBody('
'.htmlspecialchars($parts[2]).'
'); } }