Included port in database parameters
This commit is contained in:
parent
1f59e8e87c
commit
bc115c3c51
|
@ -16,12 +16,8 @@
|
||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$db = new mysqli($config['db_host'], $config['db_user'], $config['db_password']);
|
$db = new mysqli($config['db_host'], $config['db_user'], $config['db_password'], $config['db_name'], $config['db_port']);
|
||||||
|
|
||||||
if ($db->connect_error) {
|
if ($db->connect_error) {
|
||||||
die("Connection to database failed");
|
die("Connection to database failed");
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!$db->select_db($config['db_name'])) {
|
|
||||||
die("Database not available");
|
|
||||||
}
|
|
Loading…
Reference in a new issue