function _pconnect($argHostname, $argUsername, $argPassword, $argDatabasename) { $this->_connectionID = fbsql_pconnect($argHostname,$argUsername,$argPassword); if ($this->_connectionID === false) return false; if ($argDatabasename) return $this->SelectDB($argDatabasename); return true; }
public function connect($config = array()) { $this->config = $config; $this->connect = $this->config['pconnect'] === true ? @fbsql_pconnect($this->config['host'], $this->config['user'], $this->config['password']) : @fbsql_connect($this->config['host'], $this->config['user'], $this->config['password']); if (empty($this->connect)) { die(getErrorMessage('Database', 'mysqlConnectError')); } fbsql_select_db($this->config['database'], $this->connect); }
function connect_fbql($host, $user, $pass, $db) { $this->fbsql_link = fbsql_pconnect($host, $user, $pass); if ($this->fbsql_link == 0) { return false; } if (!fbsql_select_db($db, $this->fbsql_link)) { print "Database Error " . msql_error() . "\n"; return false; } return $this->fbsql_link; }