Fix attachment view on HTML-formatted emails
This commit is contained in:
parent
ab7f4e1cc1
commit
2ddb61bb55
@ -787,13 +787,22 @@ function hesk_processMessage($msg, $ticket, $is_admin, $is_ticket, $just_message
|
|||||||
// Add direct links to any attachments at the bottom of the email message
|
// Add direct links to any attachments at the bottom of the email message
|
||||||
if ($hesk_settings['attachments']['use'] && isset($ticket['attachments']) && strlen($ticket['attachments']) )
|
if ($hesk_settings['attachments']['use'] && isset($ticket['attachments']) && strlen($ticket['attachments']) )
|
||||||
{
|
{
|
||||||
|
if ($isForHtml) {
|
||||||
|
$msg .= "<br><br><br>" . $hesklang['fatt'];
|
||||||
|
} else {
|
||||||
$msg .= "\n\n\n" . $hesklang['fatt'];
|
$msg .= "\n\n\n" . $hesklang['fatt'];
|
||||||
|
}
|
||||||
|
|
||||||
$att = explode(',', substr($ticket['attachments'], 0, -1));
|
$att = explode(',', substr($ticket['attachments'], 0, -1));
|
||||||
foreach ($att as $myatt)
|
foreach ($att as $myatt)
|
||||||
{
|
{
|
||||||
list($att_id, $att_name) = explode('#', $myatt);
|
list($att_id, $att_name) = explode('#', $myatt);
|
||||||
$msg .= "\n\n" . $att_name . "\n" . $hesk_settings['hesk_url'] . '/download_attachment.php?att_id='.$att_id.'&track='.$ticket['trackid'].$hesk_settings['e_param'];
|
if ($isForHtml) {
|
||||||
|
$msg .= "<br><br>" . $att_name . "<br>";
|
||||||
|
} else {
|
||||||
|
$msg .= "\n\n" . $att_name . "\n";
|
||||||
|
}
|
||||||
|
$msg .= $hesk_settings['hesk_url'] . '/download_attachment.php?att_id='.$att_id.'&track='.$ticket['trackid'].$hesk_settings['e_param'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user