Configuration Options

Configuration Options --  Setting the defaults for HTML_Template_Flexy

Configuration

HTML_Template_Flexy can either be configured globally or on each instance, using an associated array. The easiest way to configure HTML_Template_Flexy is to use ini files (although you may also like to consider the PEAR::Config class, or your own configuration system)

To use this ini file with HTML_Template_Flexy, (and Possibly any other classes that use options like this)

Alternatively you can set (or override) the configuration when you instantate the class

Configuration Options

templateDir directory

This is the directory where all your templates are located

compileDir directory

The directory where the compiled templates will be stored, This directory should be writable by the web server

forceCompile boolean

Normally 0, means that the template will only be compiled once (or if the template file is altered), this is only really usefull if you are developing filters and need to test the result.

debug integer

The default debugging level (default 0=off), 1= shows some debugging information

locale string

Default is 'en' - english. The language use for reading/writing templates. Currently it is only used in the compiled files filename = eg. originalname.html.en.php

Flexy uses get_text() internally if it is installed, and will replace all strings in a HTML page with the return value of get_text(). - This enables the creation of multilanguage sites with a little less pain.

A file {templatename}.strings.serial is created for each file that is parsed, you can use this with PHP's unserialize function to retrieve an array of all the strings in a file. (for translating), or just use the tool xgettext.

compiler string

Default is 'Standard' - The standard Tokenizer Driver engine. Other engines available are regex (similar to Xipe's engine). You can use this field to write your own engines, either based Off the core code, or totally seperate..