mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-01-01 17:53:49 +00:00
Merge pull request #1268 from moteus/install_create_db
Fix. Create DB during web install.
This commit is contained in:
@@ -275,9 +275,9 @@ include "root.php";
|
||||
try {
|
||||
if (strlen($this->db_port) == 0) { $this->db_port = "5432"; }
|
||||
if (strlen($this->db_host) > 0) {
|
||||
$this->dbh = new PDO("pgsql:host={$this->db_host} port={$this->db_port} user={".$this->db_create_username."} password={".$this->db_create_password."} dbname=template1");
|
||||
$this->dbh = new PDO("pgsql:host={$this->db_host} port={$this->db_port} user={$this->db_create_username} password={$this->db_create_password} dbname=template1");
|
||||
} else {
|
||||
$this->dbh = new PDO("pgsql:host=localhost port={$this->db_port} user={".$this->db_create_username."} password={".$this->db_create_password."} dbname=template1");
|
||||
$this->dbh = new PDO("pgsql:host=localhost port={$this->db_port} user={$this->db_create_username} password={$this->db_create_password} dbname=template1");
|
||||
}
|
||||
} catch (PDOException $error) {
|
||||
throw new Exception("error connecting to database: " . $error->getMessage());
|
||||
|
||||
Reference in New Issue
Block a user