File size: 537B
<?php
require_once('../wu_init.php');
if (!wu_token()) { exit('wu-error'); }
if (!USER_LOGGED) { exit('wu-error'); }
include('wu_checkadmin.php');
if(isset($_POST['usr'])){
if(!empty($_POST['usr'])){
$usr = intval($_POST['usr']);
$reas = mysqli_real_escape_string($connect_db, $_POST['reas']);
if (empty($reas)) { $ban = ''; } else { $ban = '0||'.$reas; }
mysqli_query($connect_db, "UPDATE `".DB_PREFIX."_users` SET `ban` = '$ban' WHERE uid = '$usr' LIMIT 1");
exit('1');
} else { exit('wu-error'); }
} else { exit('wu-error'); }
?>