replace macros

implement new replaceMacros function
This commit is contained in:
Adam Magness
2018-10-31 10:35:50 -04:00
parent f6c86649c2
commit 91facd2d0a
91 changed files with 335 additions and 249 deletions
+2 -1
View File
@@ -5,6 +5,7 @@
use Friendica\Content\Text;
use Friendica\Core\L10n;
use Friendica\Core\Renderer;
function visible_whitespace($s)
{
@@ -140,7 +141,7 @@ function babel_content()
}
$tpl = get_markup_template('babel.tpl');
$o = replace_macros($tpl, [
$o = Renderer::replaceMacros($tpl, [
'$text' => ['text', L10n::t('Source text'), htmlentities(defaults($_REQUEST, 'text', '')), ''],
'$type_bbcode' => ['type', L10n::t('BBCode'), 'bbcode', '', defaults($_REQUEST, 'type', 'bbcode') == 'bbcode'],
'$type_markdown' => ['type', L10n::t('Markdown'), 'markdown', '', defaults($_REQUEST, 'type', 'bbcode') == 'markdown'],