Configuration Overview

There are two ways to apply settings to your Yee application. First during Yee application instantiation and second after instantiation. All settings can be applied at instantiation time by passing Yees’s constructor an associative array. All settings can be retrieved and modified after instantiation, however some of them can not be done simply by using the config application instance method but will be demonstrated as necessary below. Before we list the available settings, it is worth to quickly explain how you may define and inspect settings with your Yee application.

During Instantiation

To define settings upon instantiation, pass an associative array into the Yee constructor.

$app = new Yee(array(
    'debug' => true

After Instantiation

To define settings after instantiation, the majority can use the config application instance method; the first argument is the setting name and the second argument is the setting value.

$app->config('debug', false);

You may also define multiple settings at once using an associative array:

    'debug' => true,
    'templates.path' => '../templates'

To retrieve the value of a setting within your code, you also use the config application instance method; however, you only pass one argument - the name of the setting you wish to inspect. If the setting you request does not exist, null is returned.

$settingValue = $app->config('templates.path'); //returns "../templates"

You are not limited to the settings shown below; you may also define your own.