PHP Class c, kirby

Inheritance: use trait t
Datei anzeigen Open project: bastianallgeier/kirby Class Usage Examples

Public Methods

Method Description
get ( string $key = null, mixed $default = null ) : mixed Gets a config value by key
load ( string $file ) : array Loads an additional config file Returns the entire configuration array
set ( string $key, mixed $value = null ) Sets a config value by key

Method Details

get() static public method

Gets a config value by key
static public get ( string $key = null, mixed $default = null ) : mixed
$key string The key to look for. Pass false to get the entire config array
$default mixed The default value, which will be returned if the key has not been found
return mixed The found config value

load() static public method

Loads an additional config file Returns the entire configuration array
static public load ( string $file ) : array
$file string The path to the config file
return array The entire config array

set() static public method

Sets a config value by key
static public set ( string $key, mixed $value = null )
$key string The key to define
$value mixed The value for the passed key