From 39612a9bad3bb706ebd7167a7203559d06d37d4d Mon Sep 17 00:00:00 2001 From: phpnut Date: Sun, 16 Sep 2007 20:36:28 +0000 Subject: [PATCH] Fixes #2970, bad encoding in email send as text git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@5662 3807eeeb-6ff5-0310-8944-8be069107fe0 --- cake/libs/controller/components/email.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cake/libs/controller/components/email.php b/cake/libs/controller/components/email.php index 9fccd862e..3c5b3f0d0 100644 --- a/cake/libs/controller/components/email.php +++ b/cake/libs/controller/components/email.php @@ -423,6 +423,9 @@ class EmailComponent extends Object{ $this->__createBoundary(); $this->__header .= 'MIME-Version: 1.0' . $this->_newLine; $this->__header .= 'Content-Type: multipart/related; boundary="' . $this->__boundary . '"' . $this->_newLine; + } elseif ($this->sendAs === 'text') { + $this->__header .= 'Content-Type: text/plain; charset=' . $this->charset . $this->_newLine; + $this->__header .= 'Content-Transfer-Encoding: 8bit' . $this->_newLine; } elseif ($this->sendAs === 'html') { $this->__header .= 'Content-Type: text/html; charset=' . $this->charset . $this->_newLine; $this->__header .= 'Content-Transfer-Encoding: 8bit' . $this->_newLine;