Merge pull request #2514 from annando/1605-plaintext

Bugfix for shares in the plaintext function
This commit is contained in:
Tobias Diekershoff 2016-05-16 07:56:42 +02:00
commit 12e3c9ca59
1 changed files with 2 additions and 3 deletions

View File

@ -128,10 +128,9 @@ function get_attachment_data($body) {
if ($matches[1] != "")
$title = $matches[1];
//$title = htmlentities($title, ENT_QUOTES, 'UTF-8', false);
$title = bbcode(html_entity_decode($title, ENT_QUOTES, 'UTF-8'), false, false, true);
$title = html_entity_decode($title, ENT_QUOTES, 'UTF-8');
$title = str_replace(array("[", "]"), array("[", "]"), $title);
if ($title != "")
$data["title"] = $title;
@ -343,7 +342,7 @@ function plaintext($a, $b, $limit = 0, $includedlinks = false, $htmlmode = 2, $t
}
}
$html = bbcode($post["text"], false, false, $htmlmode);
$html = bbcode($post["text"].$post["after"], false, false, $htmlmode);
$msg = html2plain($html, 0, true);
$msg = trim(html_entity_decode($msg,ENT_QUOTES,'UTF-8'));