2024-01-18 21:47:19 +00:00
|
|
|
<?php
|
2024-01-18 23:37:42 +00:00
|
|
|
$env = parse_ini_file('.env');
|
|
|
|
$host = $env['DB_HOST'];
|
|
|
|
$user = $env['DB_USER'];
|
|
|
|
$pass = $env['DB_PASS'];
|
|
|
|
$db = $env['DB_NAME'];
|
|
|
|
$con = mysqli_connect($host, $user, $pass, $db);
|
2024-01-18 21:47:19 +00:00
|
|
|
|
|
|
|
if(mysqli_connect_errno()) {
|
|
|
|
echo "Failed to connect to database: " . mysqli_connect_errno();
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<title>Hello World</title>
|
|
|
|
</head>
|
|
|
|
|
|
|
|
<body>
|
|
|
|
<h1>Hello World!</h1>
|
|
|
|
</body>
|
|
|
|
</html>
|