Create annotated Starterkit

This commit is contained in:
Sonja Broda
2019-07-28 15:07:33 +02:00
parent 40f095f5de
commit aada11ac43
29 changed files with 305 additions and 21 deletions

View File

@@ -1,5 +1,15 @@
<?php
/**
* Page models extend Kirby's default page object.
* In page models you can define methods that are then available everywhere in Kirby where you call a page of the extended type.
* In this example, we define the cover method that either returns an image selected in the cover field
* or the first image in the folder.
* You can see the method in use in the `home.php`, `photography.php` and `album.php` templates
* and in the `site/blueprints/sections/albums.yml` image query
* More about models: https://getkirby.com/docs/guide/templates/page-models
*/
class AlbumPage extends Page
{
public function cover()