OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
3-31-025chanakya
/
Xpress
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
03/31/2025 06:36:42 AM
rwxr-xr-x
📄
.browserslistrc
208 bytes
03/26/2025 04:06:47 AM
rw-r--r--
📄
.gitignore
42 bytes
03/26/2025 04:06:47 AM
rw-r--r--
📄
.htaccess
803 bytes
03/26/2025 04:06:47 AM
rw-r--r--
📄
.htaccess.swp
12 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
.travis.yml
199 bytes
03/26/2025 04:06:47 AM
rw-r--r--
📄
09-01-25navbar.php
30.59 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
15-02-25viewList.php
14.86 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
17-02-25newCompaign.php
12.43 KB
03/26/2025 04:06:47 AM
rw-r--r--
📁
NLEditor
-
03/26/2025 04:21:24 AM
rwxr-xr-x
📄
addList.php
6.06 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
adi_deliveryViewList.php
11.13 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
aditya_choose.php
6 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
aditya_choose_template.php
7.52 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
aditya_viewCampaign.php
24.73 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
arvind_choose_templates.php
10.83 KB
03/26/2025 04:06:47 AM
rw-r--r--
📁
assets
-
03/26/2025 04:20:38 AM
rwxr-xr-x
📄
back_choose_template.php
7.52 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
blacklist.php
13.06 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
bounceViewList.php
14.63 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
bounce_handler.php
5.05 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
checkNotificationTopics.php
5.11 KB
03/26/2025 04:06:47 AM
rw-r--r--
📁
check_identity
-
03/26/2025 04:16:12 AM
rwxr-xr-x
📄
checknotif.php
1020 bytes
03/26/2025 04:06:47 AM
rw-r--r--
📄
choose_template.php
6.74 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
clickViewList.php
13.01 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
click_handler.php
1.75 KB
03/26/2025 04:06:47 AM
rw-r--r--
📄
complaintsViewList.php
8.41 KB
03/26/2025 04:06:48 AM
rw-r--r--
📄
complaints_handler.php
2.89 KB
03/26/2025 04:06:48 AM
rw-r--r--
📄
composer.json
200 bytes
03/26/2025 04:06:48 AM
rw-r--r--
📄
composer.lock
39.12 KB
03/26/2025 04:06:48 AM
rw-r--r--
📄
createList.php
19.13 KB
03/26/2025 04:06:48 AM
rw-r--r--
📁
credentials
-
03/26/2025 04:16:13 AM
rwxr-xr-x
📄
csv.php
12.33 KB
03/26/2025 04:06:48 AM
rw-r--r--
📁
data
-
03/26/2025 04:21:24 AM
rwxr-xr-x
📄
db.php
991 bytes
03/26/2025 04:06:48 AM
rw-r--r--
📄
deleteCampaign.php
966 bytes
03/26/2025 04:06:48 AM
rw-r--r--
📄
deleteTemplate.php
1.55 KB
03/26/2025 04:06:48 AM
rw-r--r--
📄
delete_list.php
959 bytes
03/26/2025 04:06:48 AM
rw-r--r--
📄
delete_users.php
435 bytes
03/26/2025 04:06:48 AM
rw-r--r--
📄
deliveryViewList.php
12.9 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
delivery_handler.php
3.25 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
download_Complaints.php
1.16 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
download_bounces.php
1.18 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
download_clicked.php
1.23 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
download_delivered.php
1.12 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
download_open.php
1.22 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
download_report.php
3.33 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
download_unique_open.php
1.6 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
duplicate_campaign.php
1.67 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
edit_campaign.php
1.45 KB
03/26/2025 04:06:49 AM
rw-r--r--
📄
edit_list.php
11.69 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
feedback.php
1.71 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
fetch_template.php
493 bytes
03/26/2025 04:06:50 AM
rw-r--r--
📄
footer.php
1.35 KB
03/26/2025 04:06:50 AM
rw-r--r--
📁
grfx
-
03/26/2025 04:16:13 AM
rwxr-xr-x
📄
himanshu_index.php
6.58 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
himanshu_newCompaign.php
11.25 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
housekeeping.php
24.85 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
index.php
9.9 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
insert_list.php
2.64 KB
03/26/2025 04:06:50 AM
rw-r--r--
📁
js
-
03/26/2025 04:16:13 AM
rwxr-xr-x
📄
load.php
159 bytes
03/26/2025 04:06:50 AM
rw-r--r--
📁
log
-
03/26/2025 04:16:25 AM
rwxr-xr-x
📄
main.css
1.3 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
navbar.php
22.54 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
navbar_menu.php
1.94 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
newCompaign.php
16.25 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
obc_cards.php
7.58 KB
03/26/2025 04:06:50 AM
rw-r--r--
📄
openViewList.php
14.4 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
open_handler.php
1.75 KB
03/26/2025 04:06:51 AM
rw-r--r--
📁
process
-
03/26/2025 04:16:33 AM
rwxr-xr-x
📄
process_emails.php
12.53 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
real-recipients.csv
39.48 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
resubscribe.php
6.41 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
sample.csv
55 bytes
03/26/2025 04:06:51 AM
rw-r--r--
📄
save.php
252 bytes
03/26/2025 04:06:51 AM
rw-r--r--
📄
save_campaign.php
612 bytes
03/26/2025 04:06:51 AM
rw-r--r--
📄
saved_content.html
6.48 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
send_email.php
987 bytes
03/26/2025 04:06:51 AM
rw-r--r--
📄
send_email_campaignGraph.php
2.24 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
sendgrid.php
3.62 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
showListMembers.php
11.44 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
showcase.php
7.79 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
sidebar.php
0 bytes
03/26/2025 04:06:51 AM
rw-r--r--
📄
sns_subscribe.php
5.25 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
submit_form.php
2.48 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
template_index.php
10.08 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
test-mail.csv
337 bytes
03/26/2025 04:06:51 AM
rw-r--r--
📄
test.php
969 bytes
03/26/2025 04:06:51 AM
rw-r--r--
📄
test_choose_template.php
6.51 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
test_process_emails.php
1.91 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
unsubscribe.php
6.87 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
upload_image.php
606 bytes
03/26/2025 04:06:51 AM
rw-r--r--
📁
uploads
-
03/26/2025 04:16:39 AM
rwxr-xr-x
📁
vendor
-
03/26/2025 04:21:35 AM
rwxr-xr-x
📄
verify.html
486 bytes
03/26/2025 04:06:51 AM
rw-r--r--
📄
verify.php
2.54 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
verify_email.php
5.03 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
viewCampaign.php
26.94 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
viewList.php
17.65 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
xpress_handler.php
10.51 KB
03/26/2025 04:06:51 AM
rw-r--r--
📄
znewCompaign.php
10.52 KB
03/26/2025 04:06:52 AM
rw-r--r--
📄
zunsubscribe.php
5.82 KB
03/26/2025 04:06:52 AM
rw-r--r--
📄
zzindex.php
6.8 KB
03/26/2025 04:06:52 AM
rw-r--r--
📄
zzzzindex.php
6.68 KB
03/26/2025 04:06:52 AM
rw-r--r--
📄
zzzzzindex.php
55.73 KB
03/26/2025 04:06:52 AM
rw-r--r--
Editing: housekeeping.php
Close
<?php include '../assets/php/validate.logged.php'; include 'db.php'; include '../assets/php/config.php'; include '../assets/php/function.php'; // Pagination $items_per_page = 50; $current_page = isset($_GET['page']) ? (int)$_GET['page'] : 1; $offset = ($current_page - 1) * $items_per_page; // Fetch unsubscribed $unsubscribedResult = $conn->query("SELECT s.name, s.email, s.status FROM subscribers s INNER JOIN list l ON s.list_id = l.id WHERE s.status='unsubscribed' AND l.user_id = $gUserId LIMIT $offset, $items_per_page"); $total_unsubscribed = $conn->query("SELECT COUNT(*) as count FROM subscribers WHERE status='unsubscribed'")->fetch_assoc()['count']; $total_unsubscribed_pages = ceil($total_unsubscribed / $items_per_page); // Fetch subscribed $subscribedResult = $conn->query("SELECT s.name, s.email, s.status FROM subscribers s INNER JOIN list l ON s.list_id = l.id WHERE s.status = 'subscribed' AND l.user_id = $gUserId LIMIT $offset, $items_per_page"); $total_subscribed = $conn->query("SELECT COUNT(*) as count FROM subscribers WHERE status='subscribed'")->fetch_assoc()['count']; $total_subscribed_pages = ceil($total_subscribed / $items_per_page); // blacklist logic if (isset($_POST['action']) && $_POST['action'] == 'add') { $email = $_POST['email']; $reason = $_POST['reason'] ?? ''; if (!filter_var($email, FILTER_VALIDATE_EMAIL)) { echo "Invalid email address."; exit; } $stmt = $conn->prepare("INSERT INTO blacklist (user_id, email, reason) VALUES (?, ?, ?)"); $stmt->bind_param('iss', $gUserId, $email, $reason); if ($stmt->execute()) { echo "<script>alert('Email successfully added to the blacklist.'); window.location.href='housekeeping.php';</script>"; } else { echo "<script>alert('Error adding email: " . $conn->error . "'); window.location.href='housekeeping.php';</script>"; } $stmt->close(); } // Handle removing from blacklist if (isset($_POST['action']) && $_POST['action'] == 'remove') { $email = $_POST['email']; $stmt = $conn->prepare("DELETE FROM blacklist WHERE email = ?"); $stmt->bind_param('s', $email); if ($stmt->execute()) { echo "<script>alert('Email successfully removed from the blacklist.'); window.location.href='housekeeping.php';</script>"; } else { echo "<script>alert('Error removing email: " . $conn->error . "'); window.location.href='housekeeping.php';</script>"; } $stmt->close(); } // Handle blocking by domain if (isset($_POST['action']) && $_POST['action'] == 'block_domain') { $domain = $_POST['domain']; if (empty($domain)) { echo "Domain is required."; exit; } $stmt = $conn->prepare("INSERT INTO blacklist (user_id, email, reason) VALUES (?, ?, 'Blocked by domain')"); $domainWildcard = "%@$domain"; $stmt->bind_param('is', $gUserId, $domainWildcard); if ($stmt->execute()) { echo "Domain successfully blocked."; } else { echo "Error blocking domain: " . $conn->error; } $stmt->close(); } // Handle removing by domain if (isset($_POST['action']) && $_POST['action'] == 'unblock_domain') { $domain = $_POST['domain']; if (empty($domain)) { echo "Domain is required."; exit; } $stmt = $conn->prepare("DELETE FROM blacklist WHERE email LIKE ?"); $domainWildcard = "%@$domain"; $stmt->bind_param('s', $domainWildcard); if ($stmt->execute()) { echo "Domain successfully unblocked."; } else { echo "Error unblocking domain: " . $conn->error; } $stmt->close(); } // Handle bulk email deletion if (isset($_POST['action']) && $_POST['action'] == 'bulk_delete') { $emails = $_POST['emails']; // Prepare the statement for bulk deletion $emailArray = explode(',', $emails); $placeholders = implode(',', array_fill(0, count($emailArray), '?')); $stmt = $conn->prepare("DELETE FROM blacklist WHERE email IN ($placeholders)"); $stmt->bind_param(str_repeat('s', count($emailArray)), ...$emailArray); if ($stmt->execute()) { echo "<script>alert('Email successfully removed from the blacklist.'); window.location.href='housekeeping.php';</script>"; } else { echo "<script>alert('Error removing email: " . $conn->error . "'); window.location.href='housekeeping.php';</script>"; } $stmt->close(); } // Fetch blacklisted emails $limit = 10; $page = isset($_GET['page']) ? intval($_GET['page']) : 1; $offset = ($page - 1) * $limit; $blacklistQuery = "SELECT * FROM blacklist where user_id = $gUserId LIMIT $limit OFFSET $offset"; $blacklistResult = $conn->query($blacklistQuery); // Fetch total records for pagination $totalQuery = "SELECT COUNT(*) as total FROM blacklist"; $totalResult = $conn->query($totalQuery); $totalRow = $totalResult->fetch_assoc(); $totalRecords = $totalRow['total']; $totalPages = ceil($totalRecords / $limit); ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Knobly Cream: Create • Reach • Measure</title> <!-- jQuery --> <script src="../assets/js/jquery-3.6.0.min.js"></script> <script src="../assets/js/jquery-3.6.0.min.js"></script> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> <!-- Font Awesome CSS --> <link rel="stylesheet" href="../assets/css/all.min.5.15.3.css"> <link rel="stylesheet" href="../assets/css/all.min.5.15.css"> <link rel="stylesheet" href="../assets/css/bootstrap.min.4.5.0.css" /> <link rel="stylesheet" href="../assets/css/animate.min.4.0.css" /> <link rel="stylesheet" href="../inc/fontawesome/css/all.min.css" /> <link rel="stylesheet" href="../inc/magnific-popup.css" /> <link rel="stylesheet" href="../inc/style.css" /> <link rel="stylesheet" href="../assets/css/styles.css"> <link rel="stylesheet" href="main.css"> <link rel="stylesheet" href="../assets/css/all.min.6.6.css"> <link rel="stylesheet" href="../assets/css/all.min.5.15.css"> <script src="../assets/js/jquery-3.6.0.min.js"></script> <script src="../assets/js/jquery-3.5.1.min.js" ></script> <script src="../assets/js/bootstrap.min.4.5.js" ></script> <script src="../assets/js/Chart.min.2.8.js" crossorigin="anonymous"></script> <script src="https://cdn.tiny.cloud/1/u5oz235qw5jiqww4udm90ocp9zg2rncblqo2ch0ym3twjgyt/tinymce/5/tinymce.min.js" referrerpolicy="origin"></script> <script src="../assets/js/zf-widget.js"></script> <script src="../inc/jquery.magnific-popup.min.js"></script> <link href="../assets/css/bootstrap-icons.min.1.10.css" rel="stylesheet"> <script src="../inc/common.js"></script> <script type="text/javascript"> </script> <!-- Custom Styles --> <style> .table td, .table th { vertical-align: middle; color: #333; } /* Custom Sidebar Styling */ #layoutSidenav { display: block !important; min-height: 100vh; } #layoutSidenav_content { flex-grow: 1; padding-left: 0; /* Removed unnecessary padding */ } .sb-nav-fixed #layoutSidenav_content { padding-top: 5px; } .page-link { border-radius: 0.25rem; color: white; /* Ensure white text for pagination in dark mode */ } .btn-danger { color: #fff; background-color: #2b2b2b !important; border-color: #2b2b2b !important; } .btn-warning { color: rgb(255, 255, 255); background-color: #2b2b2b; border-color: #2b2b2b; } .btn-group button, .btn-group a { margin: 0 5px; } .table-responsive { margin-bottom: 20px; overflow-x: auto; /* Added horizontal scroll */ } .table thead th { background-color: #343a40; color: white; text-align: center; } .table td, .table th { vertical-align: middle; Color: black; } /* Pagination styling for dark mode */ .pagination .page-item.active .page-link { background-color: #007bff; border-color: #007bff; color: white; /* White text for active page */ } .pagination .page-link { background-color: #343a40; border: 1px solid #343a40; color: white; /* White text for links */ } /* Mobile-friendly tweaks */ @media (max-width: 768px) { #layoutSidenav { flex-direction: column; } #layoutSidenav_content { padding-left: 15px; } .pagination { font-size: 14px; /* Smaller pagination for mobile */ } } .go-back-bar { margin-top: 1px !important; } </style> <style> .sideWithMainContainer { display: flex; flex-direction: row; gap: 10px; overflow-x: hidden; } .sideMaincontent { height: 100vh; overflow-y: scroll; padding: 30px 0; } @media (min-width: 768px) { .col-md-2 { padding: 0px !important; } } @media (max-width: 768px) { .col-md-2 { display: none !important; } } .panelContent { height: 80% !important; overflow-y: auto !important; } .breadcrumb { padding: 0px; } td a { color: white !important; } #panelContent { padding-bottom: 55px !important; } </style> </head> <body class="sb-nav-fixed"> <?php include "assets/php/social_navbar.php"; ?> <div class="xpressMainConatiner" style="display: flex; flex-direction:column"> <div class="sideWithMainContainer"> <div class="col-md-2"> <? include 'assets/php/sidebar.php' ?> </div> <div id="layoutSidenav" class="col-sm-12 col-md-10 sideMaincontent"> <? include 'navbar_menu.php' ?> <div id="layoutSidenav_content"> <main> <div id="panelContent" class="container-fluid col-md-9"> <!-- Unsubscribed Users Section --> <ol class="breadcrumb my-4"> <li class="breadcrumb-item d-flex justify-content-between align-items-center w-100"> <h4>Unsubscribed Users</h4> <div class="btn-group" role="group"> <a href="resubscribe.php" class="btn btn-primary"><i class="fas fa-check"></i> Resubscribe Selected</a> </div> </li> </ol> <div class="table-responsive"> <div class="d-flex justify-content-between mb-3"> <input type="text" id="search-unsubscribed" class="form-control" placeholder="Search Unsubscribed Users..."> </div> <table class="table table-bordered table-striped"> <thead class="thead-dark"> <tr> <th>Select</th> <th>Name</th> <th>Email</th> <th>Status</th> <th>Action</th> </tr> </thead> <tbody id="unsubscribed-table-body"> <?php while ($row = $unsubscribedResult->fetch_assoc()): ?> <tr> <td><input type="checkbox" class="select-user" data-email="<?php echo htmlspecialchars($row['email']); ?>"></td> <td><?php echo htmlspecialchars($row['name']); ?></td> <td><?php echo htmlspecialchars($row['email']); ?></td> <td><?php echo htmlspecialchars($row['status']); ?></td> <td> <a href="delete_users.php?email=<?php echo urlencode($row['email']); ?>" class="btn btn-danger btn-sm" onclick="return confirm('Are you sure you want to remove this user?');">Remove</a> </td> </tr> <?php endwhile; ?> </tbody> </table> <!-- Pagination for Unsubscribed Users --> <nav aria-label="Page navigation"> <ul class="pagination justify-content-center"> <?php for ($page = 1; $page <= $total_unsubscribed_pages; $page++): ?> <li class="page-item <?php if ($page == $current_page) echo 'active'; ?>"> <a class="page-link" href="?page=<?php echo $page; ?>"><?php echo $page; ?></a> </li> <?php endfor; ?> </ul> </nav> </div> <!-- Subscribed Users Section --> <ol class="breadcrumb my-4"> <li class="breadcrumb-item d-flex justify-content-between align-items-center w-100"> <h4>Subscribed Users</h4> <div class="btn-group" role="group"> </div> </li> </ol> <div class="table-responsive"> <div class="d-flex justify-content-between mb-3"> <input type="text" id="search-subscribed" class="form-control" placeholder="Search Subscribed Users..."> </div> <table class="table table-bordered table-striped"> <thead class="thead-dark"> <tr> <th>Select</th> <th>Name</th> <th>Email</th> <th>Status</th> <th>Action</th> </tr> </thead> <tbody id="subscribed-table-body"> <?php while ($row = $subscribedResult->fetch_assoc()): ?> <tr> <td><input type="checkbox" class="select-user" data-email="<?php echo htmlspecialchars($row['email']); ?>"></td> <td><?php echo htmlspecialchars($row['name']); ?></td> <td><?php echo htmlspecialchars($row['email']); ?></td> <td><?php echo htmlspecialchars($row['status']); ?></td> <td> <a href="unsubscribe.php?email=<?php echo urlencode($row['email']); ?>" class="btn btn-warning btn-sm" onclick="return confirm('Are you sure you want to unsubscribe this user?');">Unsubscribe</a> </td> </tr> <?php endwhile; ?> </tbody> </table> <!-- Pagination for Subscribed Users --> <!-- <nav aria-label="Page navigation"> <ul class="pagination justify-content-center"> <?php for ($page = 1; $page <= $total_subscribed_pages; $page++): ?> <li class="page-item <?php if ($page == $current_page) echo 'active'; ?>"> <a class="page-link" href="?page=<?php echo $page; ?>"><?php echo $page; ?></a> </li> <?php endfor; ?> </ul> </nav> --> </div> </div> </main> <div id="panelContent" class="container-fluid"> <div class="container mt-5"> <ol class="breadcrumb my-3"> <li class="breadcrumb-item w-100" style="display:flex; justify-content:space-between; align-items:center;"> <h4>Blacklist Management</h4> </li> </ol> <!-- Form to Add Email to Blacklist --> <form action="housekeeping.php" method="post" class="mb-4"> <input type="hidden" name="action" value="add"> <div class="form-group"> <label for="email">Email to add in Blacklist:</label> <input type="email" id="email" name="email" class="form-control" required> </div> <div class="form-group"> <label for="reason">Reason (optional):</label> <textarea id="reason" name="reason" class="form-control"></textarea> </div> <button type="submit" class="btn btn-primary">Add to Blacklist</button> </form> <!-- Form to Remove Email from Blacklist --> <form action="housekeeping.php" method="post" class="mb-4"> <input type="hidden" name="action" value="remove"> <div class="form-group"> <label for="remove-email">Email to Remove from blacklist:</label> <input type="email" id="remove-email" name="email" class="form-control" required> </div> <button type="submit" class="btn btn-danger">Remove from Blacklist</button> </form> <!-- Form to Block by Domain --> <form action="housekeeping.php" method="post" class="mb-4"> <input type="hidden" name="action" value="block_domain"> <div class="form-group"> <label for="domain">Domain to Block:</label> <input type="text" id="domain" name="domain" class="form-control" placeholder="example.com" required> </div> <button type="submit" class="btn btn-warning">Block Domain</button> </form> <!-- Table of Blacklisted Emails --> <div class="table-responsive"> <table class="table table-striped"> <thead> <tr> <th>Email</th> <th>Reason</th> <th>Actions</th> </tr> </thead> <tbody> <?php while ($row = $blacklistResult->fetch_assoc()) { ?> <tr> <td><?php echo htmlspecialchars($row['email']); ?></td> <td><?php echo htmlspecialchars($row['reason']); ?></td> <td> <form action="housekeeping.php" method="post" class="d-inline"> <input type="hidden" name="action" value="remove"> <input type="hidden" name="email" value="<?php echo htmlspecialchars($row['email']); ?>"> <button type="submit" class="btn btn-danger btn-sm">Remove</button> </form> </td> </tr> <?php } ?> </tbody> </table> </div> <!-- Pagination --> <nav aria-label="Page navigation example"> <ul class="pagination justify-content-center " style="gap:10px"> <li class="page-item <?php echo $page == 1 ? 'disabled' : ''; ?>"> <a class="page-link" href="?page=<?php echo $page - 1; ?>">Previous</a> </li> <?php for ($i = 1; $i <= $totalPages; $i++) { ?> <li class="page-item <?php echo $i == $page ? 'active' : ''; ?>"> <a class="page-link" href="?page=<?php echo $i; ?>"><?php echo $i; ?></a> </li> <?php } ?> <li class="page-item <?php echo $page == $totalPages ? 'disabled' : ''; ?>"> <a class="page-link" href="?page=<?php echo $page + 1; ?>">Next</a> </li> </ul> </nav> </div> </div> </div> </div> </div> </div> <!-- Bootstrap JS and dependencies --> <script> // Select/Deselect all checkboxes $('#select-all-unsubscribed').click(function() { $('input.select-user').prop('checked', this.checked); }); $('#select-all-subscribed').click(function() { $('input.select-user').prop('checked', this.checked); }); // Search functionality $('#search-unsubscribed').on('keyup', function() { var searchTerm = $(this).val().toLowerCase(); $('#unsubscribed-table-body tr').each(function() { var rowText = $(this).text().toLowerCase(); $(this).toggle(rowText.indexOf(searchTerm) > -1); }); }); $('#search-subscribed').on('keyup', function() { var searchTerm = $(this).val().toLowerCase(); $('#subscribed-table-body tr').each(function() { var rowText = $(this).text().toLowerCase(); $(this).toggle(rowText.indexOf(searchTerm) > -1); }); }); </script> <?php include 'footer.php' ?> </body> </html>