diff --git a/Config.php b/Config.php index 2834f8f..c6c537f 100644 --- a/Config.php +++ b/Config.php @@ -5,7 +5,7 @@ $user = "root"; $password = ""; $database = "users_db"; -$conn = new mysqli("localhost", "root", "", "users_db", 3307); +$conn = new mysqli($host, $user, $password, $database); if ($conn->connect_error) { die("Koneksi gagal: " . $conn->connect_error); diff --git a/test_db.php b/test_db.php new file mode 100644 index 0000000..f103ba3 --- /dev/null +++ b/test_db.php @@ -0,0 +1,8 @@ +connect_error) { + die("❌ GAGAL: " . $conn->connect_error); +} +echo "✅ KONEKSI BERHASIL"; +?>