From ceacbb9f70a525de28c7a5229730ac9bc4dfce12 Mon Sep 17 00:00:00 2001 From: stekkel Date: Mon, 24 May 2004 18:01:59 +0000 Subject: [PATCH] Set the content-type correct so we can check on multipart/mixed in mailbox_display (printMessage). git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@7545 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- functions/imap_messages.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/functions/imap_messages.php b/functions/imap_messages.php index cdcb1c20..2f14a908 100755 --- a/functions/imap_messages.php +++ b/functions/imap_messages.php @@ -683,9 +683,12 @@ function sqimap_get_small_header_list ($imap_stream, $msg_list, $show_num=false, $type = substr($type, 0, $pos); } $type = explode("/", $type); - if(!is_array($type)) { + if(!is_array($type) || count($type) < 2) { $msg['TYPE0'] = 'text'; $msg['TYPE1'] = 'plain'; + } else { + $msg['TYPE0'] = strtolower($type[0]); + $msg['TYPE1'] = strtolower($type[1]); } break; case 'received': -- 2.25.1