📂 FileMgr
📍
/
home
/
u865173473
/
domains
/
yelagiri.co.in
/
public_html
/
admin
/
amenities
✏️ es/delete.php
⬅ Kembali
<?php session_start(); require_once '../../db.php'; if (!isset($_SESSION['admin_id'])) { header('Location: ../login.php'); exit(); } if (isset($_GET['id'])) { $id = intval($_GET['id']); // Deleting amenity also deletes from room_amenities due to CASCADE in DB, but let's be safe/aware. $stmt = $conn->prepare('DELETE FROM amenities WHERE id = ?'); $stmt->bind_param('i', $id); if ($stmt->execute()) { header('Location: index.php?success=Amenity deleted'); } else { header('Location: index.php?error=Error deleting amenity'); } } else { header('Location: index.php'); } ?>
💾 Simpan
Batal
⬅ admin
4 item
Nama
Tipe
Ukuran
Diubah
Aksi
🐘
create.php
php
1.9 KB
2026-01-25 15:46
✏️
👁️
🔤
🗑
🐘
delete.php
php
657 B
2026-01-25 15:46
✏️
👁️
🔤
🗑
🐘
index.php
php
4.2 KB
2026-01-25 15:46
✏️
👁️
🔤
🗑
🐘
store.php
php
845 B
2026-01-25 15:46
✏️
👁️
🔤
🗑
✏️ Rename
Nama Baru
Simpan
Batal