<div class="event">
<h1><a href='?user=<? echo $ank['id'];?>'><? echo $ank['nick'];?></a> / История нарушений</h1>
</div>
<div class="content">
<div class="block">
<ul>
<?
if(isset($_GET['delete']) && mysql_result(mysql_querll("SELECT COUNT(*) FROM `kolhoz_ban` WHERE `id` = '".intval($_GET['delete'])."' AND `id_user` = '$ank[id]'"),0)!=0 && $ku['status']==3)
{
mysql_querll("DELETE FROM `kolhoz_ban` WHERE `id_user` = '$ank[id]' AND `id` = '".intval($_GET['delete'])."'");
}
$num=0;
$q=mysql_querll("SELECT * FROM `kolhoz_ban` WHERE `id_user` = '$ank[id]'");
while($post=mysql_fetch_array($q))
{
$num++;
$us_ban=mysql_fetch_array(mysql_querll("SELECT * FROM `kolhoz_user` WHERE `id` = '$post[id_who]'"));
echo "<li><span class='minor'><span>$num</span>.</span><span> <span>".($post['izg']==1?'Изгнание':"Обет Молчания до ".vremja($post['time']))."</span>, выдал".($us_ban['pol']==0?'a':null)." <span>";
echo on_k($us_ban['id']);
echo "<a href='?user=$us_ban[id]'>".nc($us_ban['id'])."</a></span><span>, (".output_text($post['msg']).")</span>".($ku['status']==3?" <a href='?user=$ank[id]&bans&delete=$post[id]'>[удалить]</a>":null)."</li>";
}
echo '</ul></div>';
//if(($ku['id']==1 || $ku['status']>0) && $ku['id']!=$ank['id'])echo "<div><a href='?user=$ank[id]&ban'>Выдать Обет молчания</a></div>";
//if(($ku['id']==1 || $ku['status']==1 || $ku['status']==3) && $ku['id']!=$ank['id'])echo "<div><a href='?user=$ank[id]&izg'>Выдать Изгнание</a></div>";
include_once 'inc/foot.php';
?>