Browse Source

fetch header in case of message/rfc822 attachments to let list-commands work
and to see xmailer and priority information

stekkel 23 năm trước cách đây
mục cha
commit
8b067f99ba
1 tập tin đã thay đổi với 4 bổ sung2 xóa
  1. 4 2
      src/read_body.php

+ 4 - 2
src/read_body.php

@@ -584,8 +584,10 @@ $messages[$uidvalidity][$passed_id] = $message;
 
 if (isset($passed_ent_id)) {
    $message = $message->getEntity($passed_ent_id);
-   $message->id = $passed_id;
-   $message->mailbox = $mailbox;
+   $read = sqimap_run_command ($imapConnection, "FETCH $passed_id BODY[$passed_ent_id.HEADER]", true, $response, $msg, $uid_support);
+   $rfc822_header = new rfc822_header();
+   $rfc822_header->parseHeader($read);
+   $message->rfc822_header = $rfc822_header;
 } else {
    $passed_ent_id = 0;
 }