mmk2410.org/site/templates/scribbles.php
Marcel Kapfer 0d40b85f76
All checks were successful
Deploy / deploy (push) Successful in 3s
Add scribbles
2025-01-31 22:04:40 +01:00

34 lines
882 B
PHP
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
/**
* @var Kirby\Cms\Page $page
* @var Kirby\Cms\Pages $scribbles
*/
?>
<?php snippet('layout', slots: true) ?>
<?php slot() ?>
<h1><?= $page->title() ?></h1>
<?= $page->text()->kirbytext() ?>
<?php foreach($scribbles as $scribble): ?>
<?php snippet('scribble', ['scribble' => $scribble, 'singlePage' => false]) ?>
<?php endforeach ?>
<?php if ($scribbles->pagination()->hasPages()): ?>
<nav class="pagination">
<?php if ($scribbles->pagination()->hasNextPage()): ?>
<a class="page-item next" href="<?= $scribbles->pagination()->nextPageURL() ?>">
older scribbles
</a>
<?php endif ?>
<?php if ($scribbles->pagination()->hasPrevPage()): ?>
<a class="page-item prev" href="<?= $scribbles->pagination()->prevPageURL() ?>">
newer scribbles
</a>
<?php endif ?>
</nav>
<?php endif ?>
<?php endslot() ?>