Sfoglia il codice sorgente

Set the content-type correct so we can check on multipart/mixed in
mailbox_display (printMessage).

stekkel 21 anni fa
parent
commit
ca8d8b640f
1 ha cambiato i file con 4 aggiunte e 1 eliminazioni
  1. 4 1
      functions/imap_messages.php

+ 4 - 1
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':