Skip to content

Kirby 3.6.6

PageRules::delete()

Validates if the page can be deleted

PageRules::delete(Kirby\Cms\Page $page, bool $force = false): bool

Parameters

Name Type Default
$page * Kirby\Cms\Page
$force bool false

Return type

bool

Exceptions

Type Description
Kirby\Exception\LogicException If the page has children and should not be force-deleted
Kirby\Exception\PermissionException If the user is not allowed to delete the page

Parent class

Kirby\Cms\PageRules