{{ PageBuilder::block($block_name, $options) }}
ie. {{ PageBuilder::block('colour') }}
returns option value
In the theme admin section, you can manage select fields via the "Manage block select options" link. Here you can add option names and values.
Database setup for admin select:
Option values can be entered into the database table "block_selectopts" (in a future release, these will be manageable through the admin)
Note: if the option values are hexidecimal colour codes it will add the colour to the dropdown
{{ PageBuilder::block($block_name, $options) }}
ie. @foreach (PageBuilder::block('colours') as $colour)
returns array of option values
Database setup for admin select:
Currently requires option values to be entered into the database table "block_selectopts"
Note: if the option values are hexidecimal colour codes it will add the colour to the dropdown
{{ PageBuilder::block($block_name, $options) }}
ie. {{ PageBuilder::block('link_page') }}
returns selected page id
{!! PageBuilder::block($block_name, $options) !!}
ie. {!! PageBuilder::block('interesting_pages', ['view' => 'thingy']) !!}
returns select pages template
Method options ($options):
'view' => 'custom' (defaut: is the block name)
'reverse' => true (default: will pass selected pages to the select page template, however if set to true it will pass any page that has the current page id selected in this block)
Template Location:
/blocks/selectpages/[template].blade.php
template is the block name unless a customer view is specified
Avaliable Variables:
$pages (array of stdClass below)
$page->id (int - page id)
$page->name (string - page name)
$page->full_name (string - page name with full path)
$page->url (string - page url)
example:
@foreach($pages as $page)
<li><a href="{{ $page->url }}" title="{{ $page->name }}">{{ $page->name }}</a></li>
@endforeach
Based on Laravel 5
Additional features always being planned/researched
"git" involved
Announcing (belatedly) Coaster CMS version 5.5...
So, somewhat belatedly we have launched Coaster CMS version 5.5, which is now based on Laravel v5.5 (LTS) and mostly includes a major "under the hood" update that will make Coaster more stable and als...
Coaster CMS v5.4 is here
So, Coaster CMS v5.4 has arrived and I'm just going to give you an overview of the new features. We think this update will really help people grasp the concepts around Coaster and give you ideas o...
Where is Data Stored in Coaster CMS
We've had a couple of discussions recently with people trying to understand the data structure of Coaster and more specifically, where data is stored in Coaster CMS and I thought I'd summarise some of...