localhost and server configuration are the same.
This commit is contained in:
+4
-11
@@ -6,17 +6,10 @@ $dotenv->safeLoad();
|
|||||||
$db_pass = $_ENV['DATABASE_PASSWORD'];
|
$db_pass = $_ENV['DATABASE_PASSWORD'];
|
||||||
|
|
||||||
// Make some constants
|
// Make some constants
|
||||||
if ($_SERVER['HTTP_HOST'] == 'localhost') {
|
define('HOST', '173.255.248.228');
|
||||||
define('HOST', 'localhost');
|
define('USER', 'root');
|
||||||
define('USER', 'root');
|
define('PASS', $db_pass);
|
||||||
define('PASS', $db_pass);
|
define('DB', 'palindromes');
|
||||||
define('DB', 'palindromes');
|
|
||||||
} else {
|
|
||||||
define('HOST', 'cs2440.joshashton.dev');
|
|
||||||
define('USER', 'root');
|
|
||||||
define('PASS', $db_pass);
|
|
||||||
define('DB', 'palindromes');
|
|
||||||
}
|
|
||||||
|
|
||||||
// Connect to the DB
|
// Connect to the DB
|
||||||
$conn = mysqli_connect(HOST, USER, PASS, DB);
|
$conn = mysqli_connect(HOST, USER, PASS, DB);
|
||||||
|
|||||||
Reference in New Issue
Block a user