From f7c020af04426483f875b742599defab10926c7c Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Sun, 14 Oct 2018 07:44:07 -0400 Subject: [PATCH] Add HTML result boxes to mod/babel --- mod/babel.php | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/mod/babel.php b/mod/babel.php index e5ae96be7..65287b9f2 100644 --- a/mod/babel.php +++ b/mod/babel.php @@ -114,6 +114,17 @@ function babel_content() 'content' => visible_whitespace($bbcode) ]; + $html2 = Text\BBCode::convert($bbcode); + $results[] = [ + 'title' => L10n::t('HTML::toBBCode => BBCode::convert'), + 'content' => $html2 + ]; + + $results[] = [ + 'title' => L10n::t('HTML::toBBCode => BBCode::convert (raw HTML)'), + 'content' => htmlspecialchars($html2) + ]; + $markdown = Text\HTML::toMarkdown($html); $results[] = [ 'title' => L10n::t('HTML::toMarkdown'),