Compare commits

..

No commits in common. "1d536b42f5ac1491649dfb0a6d5764f973650f84" and "91ea5d8bb3034031db258a0e39ca54d12635417e" have entirely different histories.

View File

@ -63,18 +63,14 @@ if (isset($_POST['btn-register'])) {
$insert->bind_param("sss", $username, $email, $hash);
if ($insert->execute()) {
// TUTUP DISINI (Sebelum pindah halaman)
$insert->close();
// PERUBAHAN DISINI: Tambahkan ?success=register agar JS menampilkan pesan hijau
header("Location: index.php?success=register");
exit;
} else {
// TUTUP DISINI JUGA (Sebelum pindah halaman)
$insert->close();
header("Location: index.php?register_error=Gagal mendaftar, coba lagi nanti.");
exit;
}
$insert->close();
}
/* =====================================================