mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-08 08:57:03 +03:00
Fix ConvertHtmlToPlain
This commit is contained in:
parent
d36b563e4b
commit
9188228f5d
1 changed files with 8 additions and 4 deletions
|
|
@ -1529,8 +1529,6 @@ class HtmlUtils
|
||||||
'/<th[^>]*>(.+?)<\/th>/i',
|
'/<th[^>]*>(.+?)<\/th>/i',
|
||||||
'/ /i',
|
'/ /i',
|
||||||
'/"/i',
|
'/"/i',
|
||||||
'/>/i',
|
|
||||||
'/</i',
|
|
||||||
'/&/i',
|
'/&/i',
|
||||||
'/©/i',
|
'/©/i',
|
||||||
'/™/i',
|
'/™/i',
|
||||||
|
|
@ -1573,8 +1571,6 @@ class HtmlUtils
|
||||||
"\t\\1\n",
|
"\t\\1\n",
|
||||||
' ',
|
' ',
|
||||||
'"',
|
'"',
|
||||||
'>',
|
|
||||||
'<',
|
|
||||||
'&',
|
'&',
|
||||||
'(c)',
|
'(c)',
|
||||||
'(tm)',
|
'(tm)',
|
||||||
|
|
@ -1601,6 +1597,14 @@ class HtmlUtils
|
||||||
$sText = \preg_replace("/\n\\s+\n/", "\n", $sText);
|
$sText = \preg_replace("/\n\\s+\n/", "\n", $sText);
|
||||||
$sText = \preg_replace("/[\n]{3,}/", "\n\n", $sText);
|
$sText = \preg_replace("/[\n]{3,}/", "\n\n", $sText);
|
||||||
|
|
||||||
|
$sText = \preg_replace(array(
|
||||||
|
'/>/i',
|
||||||
|
'/</i'
|
||||||
|
), array(
|
||||||
|
'>',
|
||||||
|
'<'
|
||||||
|
), $sText);
|
||||||
|
|
||||||
return \trim($sText);
|
return \trim($sText);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue