Unified email reports

This commit is contained in:
Frank John Begornia
2026-01-02 01:19:07 +08:00
parent 2e1ad5526c
commit d0d82aa8e1
229 changed files with 7374 additions and 812 deletions

View File

@@ -1,18 +1,18 @@
<?php
$host = "localhost";
$username = "root";
$password = "";
$db = "custom_design";
// Use environment variables for Docker deployment
$host = getenv('DB_HOST') ?: 'localhost';
$username = getenv('DB_USER') ?: 'root';
$password = getenv('DB_PASS') ?: '';
$db = getenv('DB_NAME') ?: 'custom_designs';
$port = getenv('DB_PORT') ?: '3306';
try{
// database connection
$conn = new PDO("mysql:host=$host;dbname=$db",$username,$password);
$conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
$conn = new PDO("mysql:host=$host;port=$port;dbname=$db", $username, $password);
$conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
}
catch(PDOException $pe)
{
die('Connection error, because: ' .$pe->getMessage());
}
$baseURL = 'http://'.$_SERVER['HTTP_HOST'] . '/bulacanlibrary/';
}