Det består av en class som man initierar med en array med taggar som skall byta ut i en fil.
Documentation:
Template class
PHP Syntax:
$template = new Template('temp_name',
à array('PROP_NAME1'=>'PROP_VAL1','ARG_PROP2'=>'PROP_VAL2', ...));
$template->Top();
...
$template->Bottom();
- Uses template files (*.tpl). Searches in the ‘template_dir’ directory defined in prepend.php.
Template Syntax:
<!-- top_start -->, <!-- top_end -->, <!-- bottom_start -->,
<!-- bottom_end -->
- These labels divide the template into two parts, top and bottom.
[NAME:default value]
- Some of the values/properties can be set by adding a array with property values as seen above. The properties must be defined in the template. The default value is only used if the property isn’t defined in the array.
- Note that the [] – syntax can cause problems with js-code.