Do not try to filter out html body as it would cause broken html content not being displayed at all

This commit is contained in:
Hadi Nategh 2021-05-28 15:12:49 +02:00
parent 579b0efa0f
commit 660ba37f47

View File

@ -3509,12 +3509,6 @@ $filter['before']= date("d-M-Y", $cutoffdate2);
}
else
{
// htmLawed filter only the 'body'
if (preg_match('`(<htm.+?<body[^>]*>)(.+?)(</body>.*?</html>)`ims', $newBody, $matches)&& !empty($matches[2]))
{
$hasOther = true;
$newBody = $matches[2];
}
$htmLawed = new Api\Html\HtmLawed();
// the next line should not be needed, but produces better results on HTML 2 Text conversion,
// as we switched off HTMLaweds tidy functionality