File size: 2.4Kb
<?php
$title = 'Аккаунт заблокирован';
require_once './element_include/element_head.php';
require_once './element_include/element_header_user_true.php';
if (empty($user['lost_block_info'])) { header('Location: /user'); exit; }
// 0 - Время выдачи блока, 1 - Выдал блок, 2 - На сколько блок (0 - не снимается), 3 - Причина блока
$block_info = explode('(::||&&&&&&&&&||::)', $user['lost_block_info']);
$profile_block_out = cache_user($block_info[1]);
if ($go == 'exit') {
setcookie('id', "", time()-3600*24*365, '/');
setcookie('password', "", time()-3600*24*365, '/');
header('Location: /');
exit;
}
if ($block_info[4] > 0) {
$timer = $block_info[2] - time();
if ($timer <= 0) {
$user['lost_block_info'] = '';
writecache('element_users_id_'.$user['lost_id'],$user);
mysql_query("UPDATE `element_user` SET `lost_block_info` = '' WHERE `lost_id` = '$user[lost_id]' LIMIT 1");
header('Location: /user');
exit;
}
if ($timer > 86400) {
$tt = (int)($timer / 86400);
$tt_1 = $tt * 86400;
$timer = $timer - $tt_1;
$tt = $tt.'д.';
$timer_1 = date("$tt Hч iм sс", mktime(0, 0, $timer));
} else $timer_1 = date("Hч iм sс", mktime(0, 0, $timer));
}
echo '<div class="nfl p5 mb5 mlra">';
echo '<div class="cntr small mb5 ccc">Ваш аккаунт заблокирован, за нарушение правил игры.</div>';
echo '<span class="small white">Время: <span class="yellow1">'.rdate("d M Y, H:i", $block_info[0]).'</span></span><br/>';
echo ($block_info[4] > 0) ? '<span class="small white">Тип блока: <span class="yellow1">'.($block_info[4] / 86400).' дн.</span></span><br/>' : '';
echo ($block_info[4] > 0) ? '<span class="small white">Осталось: <span class="admin">'.$timer_1.'</span></span><br/>' : '';
echo '<span class="small white">Выдал: <span class="yellow1">'.$profile_block_out['lost_login'].'</span></span><br/>';
echo '<span class="small white">Причина: <span class="yellow1">'.nl2br($block_info[3]).'</span></span><br/>';
echo '<div class="cntr"><a class="btn w50 p5" href="/?go=exit">
<span class="el"><span class="er">
<span class="ttl">Выход</span>
</span></span>
</a>';
echo '</div></div>';
require_once './element_include/element_foot_user_true.php';
exit;
?>