| Server IP : 3.111.61.48 / Your IP : 216.73.216.67 Web Server : Apache System : Linux ip-10-0-5-176 6.8.0-1057-aws #60~22.04.1-Ubuntu SMP Wed May 27 08:16:59 UTC 2026 x86_64 User : ubuntu ( 1000) PHP Version : 8.2.31 Disable Function : exec,passthru,shell_exec,system MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /var/www/vhost/gyaniguru.org/admin/ |
Upload File : |
<?php
include_once '../inc/DatabaseMysql.class.php';
// Instantiate DB & connect
$database = new DatabaseMysql();
$conn = $database->connect();
// Get section keyword
$reset_section = isset($_POST['reset_section']) ? mysqli_escape_string($conn, trim($_POST['reset_section'])) : null;
$res = ['status' => 'error', 'msg' => 'Something went wrong!'];
// check if the section keyword is null
if ($reset_section) {
// Query sting for update records
$query_string = "UPDATE dynamic_contents SET flag_value = null WHERE flag_type = '$reset_section';";
// Execute query
$query_exe = mysqli_query($conn, $query_string) or die(mysqli_error($conn));
// If query executed successfully, return success msg
if ($query_exe) {
$res = ['status' => 'success', 'msg' => 'Record reset successfully.'];
}
}
// Return response
echo json_encode($res);
?>