25 lines
484 B
PHP
25 lines
484 B
PHP
<?php
|
|
ini_set('display_errors', 1);
|
|
ini_set('display_startup_errors', 1);
|
|
error_reporting(E_ALL);
|
|
|
|
|
|
require_once 'config.php';
|
|
|
|
$projectRoot = $config["general"]["projectRoot"];
|
|
|
|
function database(){
|
|
global $config;
|
|
|
|
$db = new mysqli($config["db"]["host"], $config["db"]["user"], $config["db"]["pass"], $config["db"]["database"]);
|
|
|
|
if($db->connect_error){
|
|
die("Connection failed: " . $db->connect_error);
|
|
}
|
|
|
|
return $db;
|
|
}
|
|
|
|
function checkLogin(){
|
|
|
|
} |