Configuration Directives
The basic configuration object has 1 method for application configuration called configure() where you will place all your configuration directives and settings:
ColdBox.cfc
1
/**
2
* A simple CFC that configures a ColdBox application. You can even extend, compose, strategize and do your OO goodness.
3
*/
4
component{
5
6
// Mandatory configuration method
7
function configure(){
8
coldbox = {
9
10
};
11
}
12
13
}
Copied!

Directives

Inside of this configuration method you will place several core and third-party configuration structures that can alter your application settings and behavior. Below are the core directives you can define:
Directive
Type
Description
cachebox
struct
An optional structure used to configure CacheBox. If not setup the framework will use its default configuration found in /coldbox/system/web/config/CacheBox.cfc
coldbox
struct
The main coldbox directives structure that holds all the coldbox settings.
struct
A structure where you will configure the application convention names
struct
A structure where you will configure environment detection patterns
flash
struct
A structure where you will configure the FlashRAM
struct
An optional structure to configure application wide interceptor behavior
array
An optional array of interceptor declarations for your application
struct
A structure where you define how the layout manager behaves in your application
layouts
array
An array of layout declarations for implicit layout-view-folder pairings in your application
logbox
struct
An optional structure to configure the logging and messaging in your application via LogBox
modules
struct
An optional structure to configure application wide module behavior
struct
An optional structure to configure individual modules installed in your application.
settings
struct
A structure where you can put your own application settings
wirebox
struct
An optional structure used to define how WireBox is loaded
Last modified 3yr ago
Copy link
Contents
Directives