The Page Bakery! © 2012 alex schenkel

Like layouts, also pages are written in a template file in pages/[page-name].html file. All Smarty template variables are accessible in a page template, too.

There are some special variables known in a page (but also in the layout, if needed) which are useful within the actual page

All layout and page content files are Smarty 3-Templates. Please refer to their documentation for an in-detail description of Smarty's possibilities.

All layout and page content files go to the pages/ directory, or wherever you set the pageDir variable in doc_config.php The filename must be pages/page-key.html. The page-key is the key you used in the pages config in doc_config.php.

An example entry for the page 'index' in the config looks as follows:

Config::set('pages',array(
	'index' => array('title' => 'Overview','iconCls'=> 'icon-home')
);

The corresponding file is pages/index.html. A very simple page template can look as follows:

<h1>Hello, World!</h1>
<p>You are on page '{$page_key}'.</p>
which ends in:

Hello, World!

You are on page 'index'.

© 2012 alexi.ch
Version 1.0 | 2012-10-13