Combining two phenomenal technologies in an effort to re-define the CMS.
<?php
use Adamgoose\PrismicIo\Model;
class Document extends Model {
protected $endpoint = 'my-endpoint-url';
protected $token = 'my-api-token';
}
<?php
Route::get('{slug}', function($slug)
{
$document = Document::findSlug($slug);
return View::make('document')
->with(compact('document'));
});
<h1>
{{$document->title}}
</h1>
{{$document->body}}
@if($document->allow_comments == 'yes')
<div id="disqus"></div>
@endif
© 2013 dannenga., LLC