-displayHtmlHeader( $subject, '', FALSE );
-
-echo '<body text="#000000" bgcolor="#FFFFFF" link="#000000" vlink="#000000" alink="#000000">'."\n" .
- /* headers (we use table because translations are not all the same width) */
- html_tag( 'table', '', 'center', '', 'cellspacing="0" cellpadding="0" border="0" width="100%"' ) .
- html_tag( 'tr',
- html_tag( 'td', '<b>'._("From").':</b> ', 'left' ,'','valign="top"') .
- html_tag( 'td', $from, 'left' )
- ) . "\n" .
- html_tag( 'tr',
- html_tag( 'td', '<b>'._("Subject").':</b> ', 'left','','valign="top"' ) .
- html_tag( 'td', $subject, 'left' )
- ) . "\n" .
- html_tag( 'tr',
- html_tag( 'td', '<b>'._("Date").':</b> ', 'left' ) .
- html_tag( 'td', htmlspecialchars($date), 'left' )
- ) . "\n" .
- html_tag( 'tr',
- html_tag( 'td', '<b>'._("To").':</b> ', 'left','','valign="top"' ) .
- html_tag( 'td', $to, 'left' )
- ) . "\n";
- if ( strlen($cc) > 0 ) { /* only show Cc: if it's there... */
- echo html_tag( 'tr',
- html_tag( 'td', '<b>'._("Cc").':</b> ', 'left','','valign="top"' ) .
- html_tag( 'td', $cc, 'left' )
- );
- }
- /* body */
- echo html_tag( 'tr',
- html_tag( 'td', '<hr style="height: 1px;" /><br />' . "\n" . $body, 'left', '', 'colspan="2"' )
- ) . "\n" .
+displayHtmlHeader($subject);
+
+$aHeaders = array();
+$aHeaders[ _("From") ] = $from;
+$aHeaders[ _("Subject") ] = $subject;
+$aHeaders[ _("Date") ] = htmlspecialchars($date);
+$aHeaders[ _("To") ] = $to;
+$aHeaders[ _("Cc") ] = $cc;
+
+$attachments_ar = buildAttachmentArray($message, $ent_ar, $mailbox, $passed_id);