mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-23 14:28:45 +01:00
* eMail: fix problem when forwarding inline some mails containing winmail.dat attachments (HelpDesk Ticket 3810) (all original attachments are probably part of the winmail.dat, so we resolve the data/attachments contained in winmail.dat)
This commit is contained in:
parent
846fa9eff9
commit
16de40a9ee
@ -858,6 +858,7 @@
|
||||
$bofelamimail->openConnection();
|
||||
if (is_array($this->sessionData) && isset($this->sessionData['attachments']))
|
||||
{
|
||||
$tnfattachments = null;
|
||||
foreach((array)$this->sessionData['attachments'] as $attachment) {
|
||||
if(is_array($attachment))
|
||||
{
|
||||
@ -874,7 +875,20 @@
|
||||
break;
|
||||
default:
|
||||
$attachmentData = $bofelamimail->getAttachment($attachment['uid'], $attachment['partID']);
|
||||
|
||||
if ($attachmentData['type'] == 'APPLICATION/MS-TNEF')
|
||||
{
|
||||
if (!is_array($tnfattachments)) $tnfattachments = $bofelamimail->decode_winmail($attachment['uid'], $attachment['partID']);
|
||||
foreach ($tnfattachments as $k)
|
||||
{
|
||||
if ($k['name'] == $attachment['name'])
|
||||
{
|
||||
$tnfpart = $bofelamimail->decode_winmail($attachment['uid'], $attachment['partID'],$k['is_winmail']);
|
||||
$attachmentData['attachment'] = $tnfpart['attachment'];
|
||||
//error_log(__METHOD__.__LINE__.$k['name'].'<->'.$attachment['name'].':'.array2string($attachmentData['attachment']));
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
$_mailObject->AddStringAttachment($attachmentData['attachment'], $_mailObject->EncodeHeader($attachment['name']), 'base64', $attachment['type']);
|
||||
break;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user