From 43786d5ceabf332c814c8d02eaf12a3f7aca6d79 Mon Sep 17 00:00:00 2001 From: stekkel Date: Thu, 7 Mar 2002 14:14:10 +0000 Subject: [PATCH] Added function to get entity header of an attached message git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@2548 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- functions/imap_messages.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/functions/imap_messages.php b/functions/imap_messages.php index 551f3ff9..34522142 100755 --- a/functions/imap_messages.php +++ b/functions/imap_messages.php @@ -298,6 +298,18 @@ function sqimap_get_message_header ($imap_stream, $id, $mailbox) { return $header; } +/**************************************************************************** + ** Wrapper function that reformats the entity header information. + ****************************************************************************/ +function sqimap_get_ent_header ($imap_stream, $id, $mailbox, $ent) { + $read = sqimap_run_command ($imap_stream, "FETCH $id:$id BODY[$ent.HEADER]", true, $response, $message); + $header = sqimap_get_header($imap_stream, $read); + $header->id = $id; + $header->mailbox = $mailbox; + return $header; +} + + /**************************************************************************** ** Wrapper function that returns entity headers for use by decodeMime ****************************************************************************/ -- 2.25.1