0
Ip-Ban
Hello! Please tell me the following script: in the database my sql if the string = "Yes", then the user is blocked by the ip, if "No", then it is blocked Thank you.
1 Respuesta
0
$sql = "SELECT * FROM user WHERE ip = '$ip";
$result = mysqli_query($conn, $sql);
while ($row = mysqli_fetch_assoc($result)) {
$string = $row["is_banned"];
}
if ($string === "No") {
/* User is not banned */
} else {
/* User is banned */
}