summaryrefslogtreecommitdiff
path: root/program/include/rcube_message.php
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2012-11-14 13:58:15 +0100
committerAleksander Machniak <alec@alec.pl>2012-11-14 13:58:15 +0100
commit52d0d949104e6b43d8daa39dad64b20cc003440c (patch)
tree228a3261bca9a362488f7fef386a47389d86c625 /program/include/rcube_message.php
parentce248f83e52092d264de23a0bd51a0233d6498e7 (diff)
Fix handling of text/enriched content on message reply/forward/edit
Diffstat (limited to 'program/include/rcube_message.php')
-rw-r--r--program/include/rcube_message.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/program/include/rcube_message.php b/program/include/rcube_message.php
index 9b8484c15..74bf4574f 100644
--- a/program/include/rcube_message.php
+++ b/program/include/rcube_message.php
@@ -198,14 +198,15 @@ class rcube_message
* Determine if the message contains a HTML part
*
* @param bool $recursive Enables checking in all levels of the structure
+ * @param bool $enriched Enables checking for text/enriched parts too
*
* @return bool True if a HTML is available, False if not
*/
- function has_html_part($recursive = true)
+ function has_html_part($recursive = true, $enriched = false)
{
// check all message parts
foreach ($this->parts as $part) {
- if ($part->mimetype == 'text/html') {
+ if ($part->mimetype == 'text/html' || ($enriched && $part->mimetype == 'text/enriched')) {
// Level check, we'll skip e.g. HTML attachments
if (!$recursive) {
$level = explode('.', $part->mime_id);