$page->parent()

Returns the parent $page object

  • return ($page)

Example

This page is a subpage of:

<a href="<?= $page->parent()->url() ?>">
  <?= html($page->parent()->title()) ?>
</a>