Output | Summit
Locale is a class to handle localization allowing you to offer your web application in different languages. Words you designate can be interchanged with the different languages your application supports.
Configuration
Below are the configuration variables for the database.
| Option | Description |
|---|---|
| default_extension | This is the default extension of your template files. |
$config['default_extension'] = 'php'; |
|
| add_default_extension | If set to true, when outputting a template you will not need to specify the extension of the template file, however if this variable is set to false you will have to specify (if any) an extension to the file name. |
Methods
Init($config)
The Init method sets the configuration for the Output class.
Locale::Init($config);
DisableAutoExtension()
This class will disable adding the default file extension for you during runtime.
Output::DisableAutoExtension();
EnableAutoExtension()
This class will enable adding the default file extension for you during runtime.
Output::EnableAutoExtension();
Display($tpl, $vars = array(), $return = false, )
Display will output the template either to the browser or to a variable. $vars is an array of the variable you want the tempalte to have access to. $return when set to true will return the template or else, by default it will echo it to the browser.
Output::Display('template', array('var1' => 'value1'), false);

