Skip to content

Kirby 3.5.7.1

$field->short()

Cuts the string after the given length and adds "…" if it is longer

$field->short(int $length, string $appendix = '…'): Kirby\Cms\Field

Parameters

Name Type Default Description
$length * int The number of characters in the string
$appendix string '…' An optional replacement for the missing rest

Return type

Kirby\Cms\Field

Example

<?= $page->title()->short(10) ?>