Created
February 13, 2015 20:19
-
-
Save ian-cox/1c6eeedb48e4250a346b to your computer and use it in GitHub Desktop.
Adding panel fields to front end Kirby templates
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php if($user = $site->user() and $user->hasRole('admin')):?> | |
<form autocomplete="off" class="form" method="post" action="/panel/api/pages/update/<?php echo kirby()->request()->path();?>"> | |
<label class="label" for="form-field-title">Title</label> | |
<input autocomplete="on" class="input" id= "form-field-title" name="title" required="" type="title" value="<?php echo $page->title() ?>"> | |
<input type="submit" value="Save"> | |
</form> | |
<?php endif;?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment