<?php
session_start();
include_once('../../config/#Config.php');
if(!$_SESSION['UserName']){
die('<script>window.location.href=\''.$config['site']['url'].'index.php\';</script>');
}
$get_AD = mysqli_query($conn, "Select * From config_admin WHERE Account = '".$_SESSION['UserName']."'");
if(!mysqli_num_rows($get_AD)){
	die('Không đủ quyền.');
}
?>
        <!-- Modal Header -->
        <div class="modal-header">
          <h4 class="modal-title">Khóa người chơi</h4>
          <button type="button" class="close" data-dismiss="modal">×</button>
        </div>
        
        <!-- Modal body -->

        <div class="modal-body">	
		    <label>Nội Dung</label>
		    <div class="form-group pass_show"> 
               <input type="text" id="text" class="form-control"/>
            </div> 
        </div>
        
        <!-- Modal footer -->
        <div class="modal-footer">
          <button type="button" class="btn btn-danger" data-dismiss="modal" onClick="kichuser();">Khóa Ngay</button>
        </div>
        <Script>
		function kichuser(){
			$.post('ajax/ajax_kichuser.php', {user:'<?=$_POST['user']?>',id:'<?=$_POST['id']?>',sv:'<?=$_POST['sv']?>',text:$('#text').val()}, function(data){
		if(data['type'] == 0){
toastr.success(data['text'], 'Thông Báo', {timeOut: 5000});				
		} else {	
toastr.info(data['text'], 'Thông Báo', {timeOut: 5000});				
		}
	},'json');
		}
		function reloadnv(){
	if($('#list_sv').val() != "-1"){
		$.post('ajax_getnv.php', {sv:'<?=$_POST['sv']?>',user:'<?=$_POST['user']?>'}, function(data){
			$('#list_char').html(data);
		});
	}
}
		</script>
				   