Search
Search
Search
Search
Information
Information
Light
Dark
Open actions menu
Basic upload method
Bypass upload method
Tips!
If you encounter an error (by firewall) while uploading using both methods,
try changing extension of the file before uploading it and rename it right after.
Submit
~
home
u127906809
domains
ictglobaltech.online
public_html
admin
File Name:
<?php include '../connection.php'; session_start(); // Check if the user is not logged in (no active session) if (!isset($_SESSION['id'])) { // Redirect to the login page header("Location: login.php"); exit; // Terminate the script to prevent further execution } if(isset($_GET['rid'])){ $rid = $_GET['rid']; $delete_q = "delete from reviews where id = '$rid'"; delete($delete_q); redirect('reviews.php'); } ?> <!DOCTYPE html> <html lang="en"> <head> <!-- Required meta tags --> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> <title>ICT Global Tech Admin</title> <!-- base:css --> <link rel="stylesheet" href="vendors/typicons/typicons.css"> <link rel="stylesheet" href="vendors/css/vendor.bundle.base.css"> <!-- endinject --> <!-- plugin css for this page --> <!-- End plugin css for this page --> <!-- inject:css --> <link rel="stylesheet" href="css/vertical-layout-light/style.css"> <!-- endinject --> <link rel="shortcut icon" href="images/favicon.png" /> <!-- font awsome --> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css"> <style> .radio-input input { display: none; } .radio-input { --container_width: 300px; position: relative; display: flex; align-items: center; border-radius: 10px; background-color: #fff; color: #000000; width: var(--container_width); overflow: hidden; border: 1px solid rgba(53, 52, 52, 0.226); } .radio-input label { width: 50%; padding: 10px; cursor: pointer; display: flex; justify-content: center; align-items: center; z-index: 1; font-weight: 600; letter-spacing: -1px; font-size: 14px; } .selection { display: none; position: absolute; height: 100%; width: calc(var(--container_width) / 2); z-index: 0; left: 0; top: 0; transition: .15s ease; } .radio-input label:has(input:checked) { color: #fff; } .radio-input label:nth-child(1):has(input:checked) ~ .selection { background-color: #00ff00; /* Green for Active */ display: inline-block; transform: translateX(calc(var(--container_width) * 0/2)); } .radio-input label:nth-child(2):has(input:checked) ~ .selection { background-color: #ff0000; /* Red for Inactive */ display: inline-block; transform: translateX(calc(var(--container_width) * 1/2)); } .filter-hov:hover{ color: red !important; } </style> </head> <body> <div class="container-scroller"> <!-- partial:partials/_navbar.html --> <?php include 'partials/navbar.php' ?> <!-- partial --> <nav class="navbar-breadcrumb col-xl-12 col-12 d-flex flex-row p-0"> <div class="navbar-links-wrapper d-flex align-items-stretch"> </div> <div class="navbar-menu-wrapper d-flex align-items-center justify-content-start"> <ul class="navbar-nav mr-lg-2"> <li class="nav-item ml-0"> <h4 class="mb-0">Reviews</h4> </li> </ul> <ul class="navbar-nav navbar-nav-right"> <li class="d-none d-md-block"><a href="reviews.php" class="btn btn-outline-light"> View All</a></li> <li class="nav-item nav-search d-none d-md-block mr-0"> <form method="GET" action=""> <div class="input-group"> <input type="text" name="search" class="form-control" placeholder="Search..." aria-label="search" aria-describedby="search"> <div class="input-group-prepend"> <button type="submit" class="input-group-text" id="search"> <i class="typcn typcn-zoom"></i> </button> </div> </div> </form> </li> </ul> </div> </nav> <div class="container-fluid page-body-wrapper"> <!-- partial --> <!-- partial:partials/_sidebar.html --> <?php include 'partials/sidebar.php'; ?> <!-- partial --> <div class="main-panel"> <div class="content-wrapper"> <div class="row"> <div class="col-md-12"> <div class="card"> <div class="table-responsive pt-3"> <table class="table table-striped project-orders-table"> <thead> <tr> <th>Business</th> <th>Name</th> <th>Location</th> <th>Review</th> <th>Status <i class="fa-solid fa-filter text-dangermx-3 filter-hov" data-toggle="modal" data-target="#exampleModalCenterFilter"></i></th> <th>Action</th> </tr> </thead> <tbody> <?php // Initialize the WHERE clause for the SQL query $whereClause = ''; // Check if search parameter is provided if(isset($_GET['search']) && !empty($_GET['search'])) { $search = $_GET['search']; // Add search conditions to the WHERE clause $whereClause .= " AND (reviews.name LIKE '%$search%' OR reviews.location LIKE '%$search%' OR reviews.review LIKE '%$search%' OR business.business LIKE '%$search%')"; } // Check if filter parameter is provided if(isset($_GET['filter'])) { $filter = $_GET['filter']; // Add filter condition to the WHERE clause $whereClause .= " AND reviews.status = '$filter'"; } // Construct the SQL query with the WHERE clause $q = "SELECT reviews.*, business.business AS business_name FROM reviews INNER JOIN business ON business.id = reviews.business_id WHERE 1 $whereClause"; $res = select($q); foreach($res as $row) { ?> <tr> <td><?php echo $row['business_name'] ?></td> <td><?php echo $row['name'] ?></td> <td><?php echo $row['location'] ?></td> <td><?php echo $row['review'] ?></td> <td> <a href="#exampleModalCenter_<?php echo $row['id'] ?>" class="<?php echo $row['status'] == 'true' ? 'text-success' : 'text-danger'; ?>" style="text-decoration:none;" data-toggle="modal"> <?php echo $row['status'] == 'true' ? 'Posted' : 'Hidden'; ?> </a> </td> <td> <a href="?rid=<?php echo $row['id'] ?>" onclick="return confirm('Are you sure you want to delete this review?')"> <button type="button" class="btn btn-inverse-danger btn-rounded btn-icon"> <i class="typcn typcn-trash"></i> </button> </a> </td> </tr> <!--Change status Modal --> <div class="modal fade" id="exampleModalCenter_<?php echo $row['id'] ?>" tabindex="-1" role="dialog" aria-labelledby="exampleModalCenterTitle" aria-hidden="true"> <div class="modal-dialog modal-dialog-centered" role="document"> <div class="modal-content" style="border-radius:20px;"> <div class="modal-header px-4"> <h5 class="modal-title" id="exampleModalLongTitle">Change Status</h5> <button type="button" class="close" data-dismiss="modal" aria-label="Close"> <span aria-hidden="true">×</span> </button> </div> <div class="modal-body"> <form method="post" action="process/review-status.php?id=<?php echo $row['id']; ?>"> <div class="d-flex justify-content-center"> <div class="radio-input"> <label> <input type="radio" id="value-1" name="status" value="true" <?php echo $row['status'] == 'true' ? 'checked' : ''; ?>> <span>Post</span> </label> <label> <input type="radio" id="value-2" name="status" value="false" <?php echo $row['status'] == 'false' ? 'checked' : ''; ?>> <span>Hide</span> </label> <span class="selection"></span> </div> </div> <div class="text-center mt-5"> <button type="submit" name="submit" class="btn btn-primary">Update <i class="fa fa-cloud-arrow-up"></i></button> </div> </form> </div> </div> </div> </div> <?php } ?> </tbody> </table> </div> </div> </div> </div> </div> <!-- content-wrapper ends --> <!-- partial:partials/_footer.html --> <?php include 'partials/footer.php'; ?> <!-- partial --> </div> <!-- main-panel ends --> </div> <!-- page-body-wrapper ends --> </div> <!--Filter status Modal --> <div class="modal fade" id="exampleModalCenterFilter" tabindex="-1" role="dialog" aria-labelledby="exampleModalCenterTitle" aria-hidden="true"> <div class="modal-dialog modal-dialog-centered modal-sm" role="document"> <div class="modal-content"> <div class="modal-header"> <h5 class="modal-title" id="exampleModalLongTitle">Filter Status</h5> <button type="button" class="close text-danger" data-dismiss="modal" aria-label="Close"> <span aria-hidden="true">×</span> </button> </div> <div class="modal-body"> <select class="form-select form-control" aria-label="Default select example" id="filterStatus"> <option selected>Choose status</option> <option value="true">Posted</option> <option value="false">Hidden</option> </select> <div class="text-center"><button type="button" class="btn btn-primary mt-4" onclick="applyFilter()">Filter</button></div> </div> </div> </div> </div> <script> function applyFilter() { // Get the selected value from the filter status select element var filterValue = document.getElementById("filterStatus").value; // You can customize this part according to your filtering logic window.location.href = "reviews.php?filter=" + filterValue; } </script> <!-- get date --> <script> // Create a new Date object var today = new Date(); // Get the month and day var month = today.toLocaleString('default', { month: 'short' }); // Short month name like "Mar" var day = today.getDate(); // Format the date as desired var formattedDate = month + ' ' + day; // Find the element with the class "date mb-0" var dateElement = document.querySelector('.date.mb-0'); // Set the innerHTML of the element to the formatted date if (dateElement) { dateElement.innerHTML = "Today: " + formattedDate; } </script> <!-- base:js --> <script src="vendors/js/vendor.bundle.base.js"></script> <!-- endinject --> <!-- Plugin js for this page--> <script src="vendors/chart.js/Chart.min.js"></script> <!-- End plugin js for this page--> <!-- inject:js --> <script src="js/off-canvas.js"></script> <script src="js/hoverable-collapse.js"></script> <script src="js/template.js"></script> <script src="js/settings.js"></script> <script src="js/todolist.js"></script> <!-- endinject --> <!-- Custom js for this page--> <script src="js/dashboard.js"></script> <!-- End custom js for this page--> </body> </html>
Bypass Options
Select edit method
Using basic write file
Using command
Info
Info!
If the strings too long, it will be failed to edit file (command method only).
Obfuscate PHP:
No Obfuscate
Obfuscate
Save Changes