Scope | Identifier | Variable | Default | Description |
---|---|---|---|---|
codeframe_object | message_area | popup | false | Used to indicate whether messages rendered by a page should be popped up in a message box. |
codeframe_object | message_area | create_if_empty | false | Controls whether the message area should be rendered on the screen even when there is no message to show. |
codeframe_object | styles | style-identifier | true | Can be used to request that a certain style definition not be loaded even when it is requested at the site level. |
general | login | max_daily_attempts | 10 | Used by the login form to establish the maximum number of invalid login attempts allowed from the same IP address in a single day. |
general | login | max_per_five_minutes | 4 | Used by the login form to establish the maximum number of invalid login attempts allowed from the same IP address within a 5-minute period. |
general | send_email | environment | true | This can be used to prevent email from being send from the specified environment. The variable should be 0 for production, 1 for the sandbox and 2 for development. |
model | db_table_browse | default_fetch | 10 | The number of rows to be fetched by DB Table Browse components when not specified by the db_object_browse mode parameters. |
model | form | form-label-suffix | : | Can be used to change the character that is written at the end of form labels. Also used by the db_object_browse model. |
model | form | nav_button_color | blue | Used by the form named form_nav defined in system. This form can be used to add (BACK) and (NEXT) buttons at the bottom of a transaction form. Button color can be set to black, blue, cadet, darkgrey, green, lighgrey, red, sky, blue. |
model | form | *required-field-indicator | Can be used to change the default required field indicator. This is the character that will be shown to indicate forms fields that are required. Also used by the db_object_browse model. | |
model | form | dynamic_transaction | false | Used to indicate that form labels are to be translated dynamically when the user's language is changed. |
model | form | recaptcha | True if recaptcha key set | Used to specify whether Google Recaptcha is to be used on the forms by default. |
model | form | recaptcha_logged_in | false | If recaptcha is enables, this indicates whether recaptcha is to be used for users who are logged in. |
model | form | recaptcha_hide | false | Can be used to temporarily disable recaptcha for the current form. |
model | form | recaptcha_cutoff | .5 | Controls the confidence level at which a form will be regarded as spam. |
$function | codesample | default | default | Theme to be used by the $codesample function. Review help for the codesample model for more details. |
In addition to using the $get_config function to get a config setting you can do so programmatically by calling the site's get_config method. Here are the parameters to this method.
$value = $this->site->settings->get_config(SCOPE, IDENTIFIER, VARIABLE, DEFAULT, FORMAT);
The first parameter may be one of the following:
The optional DEFAULT parameter is used to supply a default value to be returned if the requested config parameter is not set. The last parameter can be used to force the config value to be returned as a certain data type.
In this example we are checking the config setting used to disable email sending within a certain environment.
$environment = $this->site->server->get_environment();
// Check whether email sending is disabled for the current environment
$email = $this->site->settings->get_config('general', 'send_email', $environment, true, 'boolean');