projects
/
Pman.Core
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
f895ca8
)
DataObjects/Core_email.php
author
Alan Knowles
<alan@roojs.com>
Thu, 3 May 2018 02:14:02 +0000
(10:14 +0800)
committer
Alan Knowles
<alan@roojs.com>
Thu, 3 May 2018 02:14:02 +0000
(10:14 +0800)
DataObjects/Core_email.php
patch
|
blob
|
history
diff --git
a/DataObjects/Core_email.php
b/DataObjects/Core_email.php
index
170c2a1
..
5844e6d
100644
(file)
--- a/
DataObjects/Core_email.php
+++ b/
DataObjects/Core_email.php
@@
-535,8
+535,21
@@
Content-Transfer-Encoding: 7bit
mkdir(dirname($cachePath), 0700, true);
}
mkdir(dirname($cachePath), 0700, true);
}
- file_put_contents($cachePath, $this->bodytext);
+ if (empty($this->use_file)) {
+ file_put_contents($cachePath, $this->bodytext);
+ return;
+ }
+ // use-file
+ $mailtext = file_get_contents($this->use_file);
+
+ require_once 'Mail/mimeDecode.php';
+ require_once 'Mail/RFC822.php';
+
+ $decoder = new Mail_mimeDecode($mailtext);
+ $parts = $decoder->getSendArray();
+ file_put_contents($parts[2], $this->bodytext);
+
}
function cachedImages()
}
function cachedImages()