Skip to content

Kirby 4.4.1

kirbytext()

Parses KirbyTags and Markdown in the given string. Shortcut for $kirby->kirbytext()

kirbytext(?string $text = null, array $data = [ ]): string

Parameters

Name Type Default
$text string|null null
$data array [ ]

Return type

string

Alias

kt()

Example

<?= kirbytext($page->text()) ?>
<?= kt($page->text()) ?>

Parse KirbyText for another page

<?= kirbytext('(image: road.jpg)', ['parent' => $page->children()->first()]) ?>