From 8f5425ec4d036c4ac8b9858cfcbbc793a1929ff2 Mon Sep 17 00:00:00 2001 From: stekkel Date: Thu, 15 Aug 2002 14:15:47 +0000 Subject: [PATCH] formatting formatAttachments moved to read_body.php git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@3308 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- functions/mime.php | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) diff --git a/functions/mime.php b/functions/mime.php index 74153d77..6b6fd2a6 100644 --- a/functions/mime.php +++ b/functions/mime.php @@ -192,7 +192,6 @@ function mime_print_body_lines ($imap_stream, $id, $ent_id, $encoding) { /* -[ END MIME DECODING ]----------------------------------------------------------- */ - /* findDisplayEntity * Checks to see if $message contains content of type $type0/$type1 * returns the first entity number it finds of that type, or NULL if @@ -210,6 +209,7 @@ function findDisplayEntity($message, $type0, $type1, $start=0) { } return NULL; } + // This is here for debugging purposese. It will print out a list // of all the entity IDs that are in the $message object. @@ -375,11 +375,7 @@ function formatAttachments($message, $exclude_id, $mailbox, $id) { if (!count($att_ar)) return ''; - $attachments = "\n" . - "
\n" . - _("Attachments") . ':' . - "
\n" . - "\n"; + $attachments = ''; $urlMailbox = urlencode($mailbox); @@ -419,7 +415,7 @@ function formatAttachments($message, $exclude_id, $mailbox, $id) { $Links = $HookResults[1]; $DefaultLink = $HookResults[6]; - $attachments .= '" . '' . @@ -445,6 +441,7 @@ function formatAttachments($message, $exclude_id, $mailbox, $id) { $attachments .= '' . $Val['text'] . ''; } unset($Links); + $attachments .= "\n"; } else { $filename = decodeHeader($header->getParameter('filename')); if (trim($filename) == '') { @@ -487,7 +484,7 @@ function formatAttachments($message, $exclude_id, $mailbox, $id) { $Links = $HookResults[1]; $DefaultLink = $HookResults[6]; - $attachments .= '" . '' . @@ -507,14 +504,11 @@ function formatAttachments($message, $exclude_id, $mailbox, $id) { } $attachments .= '' . $Val['text'] . ''; } - + $attachments .= "\n"; unset($Links); } - } - $attachments .= "\n"; - - $attachments .= "
  ' . + $attachments .= '
' . "$display_filename ' . show_readable_size($header->size) . '  
  ' . + $attachments .= '
' . "$display_filename ' . show_readable_size($header->size) . '  
"; + } return $attachments; } @@ -1603,4 +1597,4 @@ function magicHTML($body, $id, $message, $mailbox = 'INBOX'){ return $trusted; } -?> +?> \ No newline at end of file -- 2.25.1