Skip to content

Commit

Permalink
Convert first with Api\Translation::convert, then decode with html_en…
Browse files Browse the repository at this point in the history
…tity_decode()
  • Loading branch information
asig2016 committed Apr 1, 2019
1 parent eba66e8 commit 1f2080e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions api/src/Mail/Html.php
Original file line number Diff line number Diff line change
Expand Up @@ -404,6 +404,7 @@ static function convertHTMLToText($_html,$displayCharset=false,$stripcrl=false,$
$_html = str_replace('#greater#than#','>',$_html);
//error_log(__METHOD__.__LINE__.' Charset:'.$displayCharset.' -> '.$_html);
$_html = Api\Translation::convert($_html, $displayCharset, 'utf-8');
$_html = html_entity_decode($_html, ENT_COMPAT, 'utf-8');
//error_log(__METHOD__.__LINE__.' Charset:'.$displayCharset.' After html_entity_decode: -> '.$_html);
//self::replaceEmailAdresses($_html);
$pos = strpos($_html, 'blockquote');
Expand Down

0 comments on commit 1f2080e

Please sign in to comment.