<?php
// cPanel Configuration
$DB_HOST = 'localhost';  // cPanel uses localhost for local databases
$DB_NAME = 'username_hse_management';  // Replace 'username' with your cPanel username
$DB_USER = 'username_hse_user';        // Replace 'username' with your cPanel username
$DB_PASS = 'YOUR_PASSWORD_HERE';       // Password you created in MySQL Databases

$mysqli = new mysqli($DB_HOST, $DB_USER, $DB_PASS, $DB_NAME);
if ($mysqli->connect_error) {
    http_response_code(500);
    header('Content-Type: application/json');
    echo json_encode(['error' => 'Database connection failed', 'details' => $mysqli->connect_error]);
    exit;
}
$mysqli->set_charset('utf8mb4');
?>
