X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=blobdiff_plain;f=functions%2Fmime.php;h=61e345741c836eedaf62ebdb31d92f3345288819;hp=6e11b1d067c69d3928a9e2aaa330ab5add00d2cd;hb=e22815bedcfe6c67cd526f7f4c9766e4363547ee;hpb=794b2d0a8315518a82ad1d6f1af71eeb5cc603ed diff --git a/functions/mime.php b/functions/mime.php index 6e11b1d0..61e34574 100644 --- a/functions/mime.php +++ b/functions/mime.php @@ -811,7 +811,13 @@ function formatBody($imap_stream, $message, $color, $wrap_at) { /** Display the ATTACHMENTS: message if there's more than one part **/ if (isset($message->entities[1])) { - $body .= formatAttachments ($message, $ent_num, $message->header->mailbox, $id); + /* Header-type alternative means we choose the best one to display + so don't show the alternatives as attachment. Header-type related + means that the attachments are already part of the related message. + */ + if ($message->header->type1 !='related' && $message->header->type1 !='alternative') { + $body .= formatAttachments ($message, $ent_num, $message->header->mailbox, $id); + } } } else { $body = formatAttachments ($message, -1, $message->header->mailbox, $id);