This commit is contained in:
mei 2024-11-02 13:14:54 +08:00
parent 75b049f6d3
commit 242feb39ba
3 changed files with 2 additions and 14 deletions

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
/core/db.php

View File

@ -1,13 +0,0 @@
<?php
$host = '1Panel-mysql-x'; // 数据库地址
$db = ''; // 数据库名
$user = ''; // 数据库用户名
$pass = ''; // 数据库密码
try {
$pdo = new PDO("mysql:host=$host;dbname=$db", $user, $pass);
$pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
} catch (PDOException $e) {
echo "Connection failed: " . $e->getMessage();
}
?>

View File

@ -1,5 +1,5 @@
<?php <?php
include 'core/config.php'; include 'core/db.php';
include 'core/clean.php'; include 'core/clean.php';
// TODO: cookie management // TODO: cookie management