Skip to content

Kirby 4.5.0

$field->isEmpty()

Checks if the field content is empty

$field->isEmpty(): bool

Return type

bool

Example

<?php if ($page->address()->isEmpty()): ?>
No address available
<?php endif ?>