From 6b90558b7ab9f0d89f6a04b1a800d4c5b09e8e2d Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 20 Apr 2018 11:20:56 +0200 Subject: [PATCH] FIX File name not visible in email preview --- htdocs/core/class/CMailFile.class.php | 2 +- htdocs/core/class/smtps.class.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/core/class/CMailFile.class.php b/htdocs/core/class/CMailFile.class.php index d9469c11559..6dbc622032d 100644 --- a/htdocs/core/class/CMailFile.class.php +++ b/htdocs/core/class/CMailFile.class.php @@ -1128,7 +1128,7 @@ class CMailFile $out.= "Content-Disposition: attachment; filename=\"".$filename_list[$i]."\"".$this->eol; $out.= "Content-Type: " . $mimetype_list[$i] . "; name=\"".$filename_list[$i]."\"".$this->eol; $out.= "Content-Transfer-Encoding: base64".$this->eol; - $out.= "Content-Description: File Attachment".$this->eol; + $out.= "Content-Description: ".$filename_list[$i].$this->eol; $out.= $this->eol; $out.= $encoded; $out.= $this->eol; diff --git a/htdocs/core/class/smtps.class.php b/htdocs/core/class/smtps.class.php index c4176d2b81b..d83ff3110ba 100644 --- a/htdocs/core/class/smtps.class.php +++ b/htdocs/core/class/smtps.class.php @@ -1410,7 +1410,7 @@ class SMTPs $content = 'Content-Type: ' . $_msgData['mimeType'] . '; charset="' . $this->getCharSet() . '"' . "\r\n" . 'Content-Transfer-Encoding: ' . $this->getTransEncodeType() . "\r\n" . 'Content-Disposition: inline' . "\r\n" - . 'Content-Description: message' . "\r\n"; + . 'Content-Description: Message' . "\r\n"; if ( $this->getMD5flag() ) $content .= 'Content-MD5: ' . $_msgData['md5'] . "\r\n"; @@ -1459,7 +1459,7 @@ class SMTPs . 'Content-Disposition: attachment; filename="' . $_data['fileName'] . '"' . "\r\n" . 'Content-Type: ' . $_data['mimeType'] . '; name="' . $_data['fileName'] . '"' . "\r\n" . 'Content-Transfer-Encoding: base64' . "\r\n" - . 'Content-Description: File Attachment' . "\r\n"; + . 'Content-Description: ' . $_data['fileName'] ."\r\n"; if ( $this->getMD5flag() ) $content .= 'Content-MD5: ' . $_data['md5'] . "\r\n";