<?php

require 'admin-login.php';

$id = $_GET['id'];

$query = mysqli_query($link, "SELECT * FROM user WHERE email = '$id' ");
$user = mysqli_fetch_array($query);

$u_email = $user['email'];
$u_id = $user['id'];

mysqli_query($link, "UPDATE user SET withdrawal_access = 'Denied', account_status = 'Blocked', trade_mode = 'Off' WHERE email = '$id' ");

header("Location: user-details.php?id=$u_id");

?>