From f9f7d3655d927ce21557127d05416cb4353d3078 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 18 Jun 2018 23:24:31 +0200 Subject: [PATCH] FIX better text content for multipart email --- htdocs/core/class/CMailFile.class.php | 2 +- htdocs/core/class/smtps.class.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/core/class/CMailFile.class.php b/htdocs/core/class/CMailFile.class.php index 51659416e30..28ee4408836 100644 --- a/htdocs/core/class/CMailFile.class.php +++ b/htdocs/core/class/CMailFile.class.php @@ -1062,8 +1062,8 @@ class CMailFile if ($this->msgishtml) { // Similar code to forge a text from html is also in CMailFile.class.php - $strContentAltText = html_entity_decode(strip_tags($strContent)); $strContentAltText = preg_replace("/]*>/"," ", $strContentAltText); + $strContentAltText = html_entity_decode(strip_tags($strContent)); $strContentAltText = rtrim(wordwrap($strContentAltText, 75, empty($conf->global->MAIN_FIX_FOR_BUGGED_MTA)?"\r\n":"\n")); // Check if html header already in message, if not complete the message diff --git a/htdocs/core/class/smtps.class.php b/htdocs/core/class/smtps.class.php index 076e307263f..8c7775a16ed 100644 --- a/htdocs/core/class/smtps.class.php +++ b/htdocs/core/class/smtps.class.php @@ -1361,8 +1361,8 @@ class SMTPs if ($strType == 'html') { // Similar code to forge a text from html is also in CMailFile.class.php - $strContentAltText = html_entity_decode(strip_tags($strContent)); $strContentAltText = preg_replace("/]*>/"," ", $strContentAltText); + $strContentAltText = html_entity_decode(strip_tags($strContent)); $strContentAltText = rtrim(wordwrap($strContentAltText, 75, "\r\n")); }