PEAR_Config::readConfigFile()

PEAR_Config::readConfigFile() -- Reads configuration data from a file

Synopsis

require_once 'PEAR/config.php';

bool PEAR_Config::readConfigFile ([string $file = NULL [, string $layer = 'user']])

Description

Reads configuration data from a file. All existing values in the config layer are discarded and replaced with data from the file.

Parameter

string $file

file to read from, if NULL or not specified, the last-used file for the same layer (second param) is used

string $layer

config layer to insert data into ('user' or 'system')

Return value

bool - Returns TRUE on success, PEAR_Error on failure.

Throws

Table 20-1. Possible PEAR_Error values

Error codeError valueMeaningSolution
 ""  

Note

This function can not be called statically.