I want to add a publication date to a top-level page and display it on all sub-pages. What is the best way to do this?
I have my template structure in Kirby set up like this:
- Issue (this is where the publication date should be set)
– Feature Story
I only want the date to show for “Issues” and their sub-pages but not on any pages outside of it. I have a date placeholder in my header.php template but I’m not sure if this is the best way to accomplish this.
This is the code snippet I currently have in header.php:
<?php echo $page->pub_date('F j, Y') ?>