- // textversion keeps linebreaks
- $textversion = strip_tags(str_replace("<br>", "\n", html_entity_decode(BBCode::convert(stripslashes(str_replace(["\\r\\n", "\\r", "\\n"], "\n",
- $body))),ENT_QUOTES, 'UTF-8')));
- $htmlversion = html_entity_decode(BBCode::convert(stripslashes(str_replace(["\\r\\n", "\\r", "\\n\\n", "\\n"],
- "<br />\n", $body))), ENT_QUOTES, 'UTF-8');