14 lines
317 B
PHP
14 lines
317 B
PHP
<?php
|
|
// Load in the database variables
|
|
$path = $_SERVER['DOCUMENT_ROOT'];
|
|
require_once($path . "/core/config.php");
|
|
|
|
function get_database_conn() {
|
|
$conn= mysqli_connect(DB_HOST, DB_USER, DB_PASSWORD, DB_NAME);
|
|
if (!$conn) {
|
|
die('Could not connect to the database host!' . mysql_error());
|
|
}
|
|
return $conn;
|
|
}
|
|
?>
|