| | |
| | | {
|
| | | global $conf;
|
| | | $this->_conf = $conf;
|
| | | if($this->_conf['start_db'] == true) {
|
| | | $this->load('db_'.$this->_conf['db_type']);
|
| | |
|
| | | if($this->_conf["start_db"] == true) {
|
| | | $this->load('db_'.$this->_conf["db_type"]);
|
| | | $this->db = new db;
|
| | |
|
| | | /*
|
| | | Initialize the connection to the master DB,
|
| | | if we are in a multiserver setup
|
| | | */
|
| | | if($this->_conf["dbmaster_host"] != '' && $this->_conf["dbmaster_host"] != $this->_conf["db_host"]) {
|
| | | $this->dbmaster = new db;
|
| | | if($this->dbmaster->linkId) $this->dbmaster->closeConn();
|
| | | $this->dbmaster->dbHost = $this->_conf["dbmaster_host"];
|
| | | $this->dbmaster->dbName = $this->_conf["dbmaster_database"];
|
| | | $this->dbmaster->dbUser = $this->_conf["dbmaster_user"];
|
| | | $this->dbmaster->dbPass = $this->_conf["dbmaster_password"];
|
| | | } else {
|
| | | $this->dbmaster = $this->db;
|
| | | }
|
| | | }
|
| | |
|
| | | //* Start the session
|