Skip to content

Kirby 6.0.0

$site->hasChildren()

Checks if the model has any published children

$site->hasChildren(): bool

Return type

bool

Parent class

Kirby\Cms\Site

Examples

<?php if ($site->hasChildren()): ?>
There are children in /content.
<?php endif ?>