This package enable Plates that Native PHP template engine/system for your own Kirby applications.

All the documentation about Plates template engine is in the official documentation.

Installation

Installation with composer

Manual

  1. Download the latest release
  2. Unzip downloaded file
  3. Copy/paste unzipped folder in your /site/plugins folder

With composer

composer require owebstudio/kirby-plates

Git submodule

git submodule add https://github.com/owebstudio/kirby-plates.git site/plugins/kirby-plates

Sample usage

/site/templates/home.php

<?php $this->layout('default') ?>

<h1>User Profile</h1>
<p>Hello, <?=$this->e($name)?></p>


<?php $this->push('scripts') ?>
  <script src="example.js"></script>
<?php $this->end() ?>

/site/templates/layouts/default.php

<html>
  <head>
    <title><?=$this->e($title)?></title>
  </head>
  <body>
    <?=$this->section('content')?>
    <?= $this->section('scripts') ?>
  </body>
</html>

Do you need custom plugin?

We will be happy to assist you by writing to us about your needs.