My Project
 All Data Structures Namespaces Functions Variables
Public Member Functions | Data Fields | Protected Member Functions
CI_Config Class Reference

Public Member Functions

 __construct ()
 
 load ($file= '', $use_sections=FALSE, $fail_gracefully=FALSE)
 
 item ($item, $index= '')
 
 slash_item ($item)
 
 site_url ($uri= '')
 
 base_url ($uri= '')
 
 system_url ()
 
 set_item ($item, $value)
 
 _assign_to_config ($items=array())
 

Data Fields

 $config = array()
 
 $is_loaded = array()
 
 $_config_paths = array(APPPATH)
 

Protected Member Functions

 _uri_string ($uri)
 

Constructor & Destructor Documentation

__construct ( )

Constructor

Sets the $config data from the primary config.php file as a class variable

public

Parameters
stringthe config file name
booleanif configuration values should be loaded into their own section
booleantrue if errors should just return false, false if an error message should be displayed
Returns
boolean if the file was successfully loaded or not

Member Function Documentation

_assign_to_config (   $items = array())

Assign to Config

This function is called by the front controller (CodeIgniter.php) after the Config class is instantiated. It permits config items to be assigned or overriden by variables contained in the index.php file

private

Parameters
array
Returns
void
_uri_string (   $uri)
protected

Build URI string for use in Config::site_url() and Config::base_url()

protected

Parameters
$uri
Returns
string
base_url (   $uri = '')

Base URL Returns base_url [. uri_string]

public

Parameters
string$uri
Returns
string
item (   $item,
  $index = '' 
)

Fetch a config file item

public

Parameters
stringthe config item name
stringthe index name
bool
Returns
string
load (   $file = '',
  $use_sections = FALSE,
  $fail_gracefully = FALSE 
)

Load Config File

public

Parameters
stringthe config file name
booleanif configuration values should be loaded into their own section
booleantrue if errors should just return false, false if an error message should be displayed
Returns
boolean if the file was loaded correctly
set_item (   $item,
  $value 
)

Set a config file item

public

Parameters
stringthe config item key
stringthe config item value
Returns
void
site_url (   $uri = '')

Site URL Returns base_url . index_page [. uri_string]

public

Parameters
stringthe URI string
Returns
string
slash_item (   $item)

Fetch a config file item - adds slash after item (if item is not empty)

public

Parameters
stringthe config item name
bool
Returns
string
system_url ( )

System URL

public

Returns
string

The documentation for this class was generated from the following file: