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
/**
* A simple CFC that configures a ColdBox application.  You can even extend, compose, strategize and do your OO goodness.
*/
component{

    // Mandatory configuration method
    function configure(){
        coldbox = {
          
        };
    }
    
}

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

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

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

struct

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

array

An array of layout declarations for implicit layout-view-folder pairings in your application

struct

An optional structure to configure the logging and messaging in your application via LogBox

struct

An optional structure to configure application wide module behavior

struct

An optional structure to configure individual modules installed in your application.

struct

A structure where you can put your own application settings

struct

An optional structure used to define how WireBox is loaded

Last updated