From c17daabaef519bbac012c5fe9132ddaccea57f4f Mon Sep 17 00:00:00 2001 From: stekkel Date: Tue, 13 Aug 2002 11:44:41 +0000 Subject: [PATCH] fix for decode different entities git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@3291 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- src/compose.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/compose.php b/src/compose.php index 8396da9c..ef06f011 100644 --- a/src/compose.php +++ b/src/compose.php @@ -465,11 +465,11 @@ function newMail ($mailbox='', $passed_id='', $passed_ent_id='', $action='', $se $encoding = $message->header->encoding; $type0 = $message->type0; $type1 = $message->type1; - foreach ($entities as $ent) { - $bodypart = decodeBody( - mime_fetch_body($imapConnection, $passed_id, $ent), - $encoding); + $unencoded_bodypart = mime_fetch_body($imapConnection, $passed_id, $ent); + $body_part_entity = $message->getEntity($ent); + $bodypart = decodeBody($unencoded_bodypart, + $body_part_entity->header->encoding); if ($type1 == 'html') { $bodypart = strip_tags($bodypart); } -- 2.25.1