<?
define('INSIDE', true);
include("../config/config.php");
$title='Инстинкты Воина - [Управление рейтингом кланов]';
$stat = mysql_fetch_array(mysql_query("SELECT * FROM `person` WHERE `user` = '".$_COOKIE['user']."' AND `pass` = '".$_COOKIE['pass']."' LIMIT 1"));
mysql_query("SET CHARSET cp1251");
if (empty($stat['id']) || $stat['bloked']|| $stat['admin']!=1) {
echo"<script>top.window.location = 'index.php?action=logout';</script>";
exit;
}
?>
<html>
<head>
<title>Администрирование кланов</title>
<link rel=stylesheet href=../img/css/main.css>
</head>
<BODY bgcolor="#EBEDEC">
<?
if (isset($_GET['top'])) { print "<CENTER><FONT class=title>Управление рейтингом кланов</FONT>
"; }
if (isset($_GET['clan'])) { print "<CENTER><FONT class=title>Управление кланами</FONT>
"; }
if ($_GET['top']=='add') {
if (isset($_POST['clan']) && isset($_POST['url']) && isset($_POST['about']) && !empty($_POST['clan']) && !empty($_POST['url']) && !empty($_POST['about'])) {
$query = mysql_query ("SELECT `clan_id` FROM `top` WHERE `clan` = '".addslashes($_POST['clan'])."'");
if (!mysql_num_rows($query)){
$insert = mysql_query("INSERT INTO `top` (`clan_id`,`clan`,`url`,`about`) VALUES (NULL,'".addslashes($_POST['clan'])."','".addslashes($_POST['url'])."','".addslashes($_POST['about'])."')");
print "<FONT class=\"agree\">Клан \"".$_POST['clan']."\" успешно добавлен в рейтинг!</FONT>
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan']."\" уже находиться в рейтинге!</FONT>
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['top']=='update') {
if (isset($_POST['clan_id']) && isset($_POST['url']) && isset($_POST['about']) && isset($_POST['hosts']) && isset($_POST['visits']) && isset($_POST['update_date']) && !empty($_POST['clan_id'])) {
$query = mysql_query ("SELECT `clan` FROM `top` WHERE `clan_id` = '".(int)$_POST['clan_id']."'");
if (mysql_num_rows($query)){
$arr = mysql_fetch_array ($query);
$update = mysql_query ("UPDATE `top` SET `url` = '".addslashes($_POST['url'])."', `about` = '".addslashes($_POST['about'])."', `hosts` = '".(int)$_POST['hosts']."', `visits` ='".(int)$_POST['visits']."', `update_date` = '".(int)$_POST['update_date']."' WHERE `clan_id` = '".(int)$_POST['clan_id']."'");
print "<FONT class=\"agree\">Клан \"".stripslashes($arr['clan'])."\" успешно обновлен в рейтинге!</FONT>
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan']."\" не найден в рейтинге!</FONT>
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
}
elseif ($_GET['top']=='delete') {
if (isset($_POST['clan']) && !empty($_POST['clan'])) {
$query = mysql_query ("SELECT `clan_id` FROM `top` WHERE `clan` = '".addslashes($_POST['clan'])."'");
if (mysql_num_rows($query)){
$delete = mysql_query("DELETE FROM `top` WHERE `clan` = '".addslashes($_POST['clan'])."'");
print "<FONT class=\"agree\">Клан \"".$_POST['clan']."\" успешно удален из рейтинга!</FONT>
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan']."\" не найден в рейтинге!</FONT>
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['top']=='edit') {
if (isset($_POST['clan']) && !empty($_POST['clan'])) {
$query = mysql_query ("SELECT * FROM `top` WHERE `clan` = '".addslashes($_POST['clan'])."'");
if (mysql_num_rows($query)){
$arr = mysql_fetch_array($query);
?>
<TABLE width="30%" align="center" cellpadding="3" cellspacing="3" border="0">
<TR>
<TD valign="top">
<FIELDSET>
<LEGEND><small class=ch>Редактирование клана "<?=stripslashes($arr['clan'])?>"</small></LEGEND>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?top=update&tmp=<?=time()?>" name="add" method="post">
<input type="hidden" name="clan_id" value="<?=$arr['clan_id']?>">
<TR>
<TD>Адрес сайта:</TD>
<TD><INPUT size="25" class="input" name="url" value="<?=stripslashes($arr['url'])?>"></TD>
</TR>
<TR>
<TD>Описание:</TD>
<TD><INPUT size="25" class="input" name="about" value="<?=stripslashes($arr['about'])?>"></TD>
</TR>
<TR>
<TD>Кол-во хостов:</TD>
<TD><INPUT size="25" class="input" name="hosts" value="<?=$arr['hosts']?>"></TD>
</TR>
<TR>
<TD>Кол-во визитов:</TD>
<TD><INPUT size="25" class="input" name="visits" value="<?=$arr['visits']?>"></TD>
</TR>
<TR>
<TD>Дата обновл.:</TD>
<TD><INPUT size="25" class="input" name="update_date" value="<?=$arr['update_date']?>"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT TYPE="button" CLASS="input" VALUE="Назад" ONCLICK="window.location='admin.php'"> <INPUT type="submit" class="input" value="Отредактировать клан"></TD>
</TR>
</FORM>
</TABLE>
</FIELDSET>
</TD>
</TR>
</TABLE>
<?
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan']."\" не найден в рейтинге!</FONT>
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['clan']=='create') {
if (isset($_POST['clan_name']) && !empty($_POST['clan_name']) && isset($_POST['b_clan']) && !empty($_POST['b_clan']) && isset($_POST['url']) && !empty($_POST['url']) && isset($_POST['about'])) {
$query_1 = mysql_query ("SELECT `id` FROM `person` WHERE `tribe` = '".addslashes($_POST['clan_name'])."'");
if (!mysql_num_rows($query_1)) {
$query_2 = mysql_query ("SELECT `id` FROM `person` WHERE `user` = '".addslashes($_POST['b_clan'])."'");
if (mysql_num_rows($query_2)) {
$create = mysql_query("UPDATE `person` SET `tribe` = '".addslashes($_POST['clan_name'])."', `b_tribe` = '1' WHERE `user` = '".addslashes($_POST['b_clan'])."'");
$create1 = mysql_query("INSERT INTO `tribes` (`name`,`url`,`about`,`name_short`) VALUES ('".addslashes($_POST['clan_name'])."','".addslashes($_POST['url'])."','".addslashes($_POST['about'])."','".addslashes($_POST['name_short'])."')");
print "<FONT class=\"agree\">Клан \"".$_POST['clan_name']."\" успешно создан! Глава клана - \"".$_POST['b_clan']."\"!</FONT>
";
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['b_clan']."\" не найден!</FONT>
"; }
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan_name']."\" уже сущесвует!</FONT>
"; }
$query_3 = mysql_query ("SELECT `clan_id` FROM `top` WHERE `clan` = '".addslashes($_POST['clan_name'])."'");
if (!mysql_num_rows($query_3)){
$add = mysql_query("INSERT INTO `top` (`clan_id`,`clan`,`url`,`about`) VALUES (NULL,'".addslashes($_POST['clan_name'])."','".addslashes($_POST['url'])."','".addslashes($_POST['about'])."')");
print "<FONT class=\"agree\">Клан \"".$_POST['clan_name']."\" успешно добавлен в рейтинг!</FONT>
";
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan_name']."\" уже находится в рейтинге!</FONT>
"; }
print "
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['clan']=='name') {
if (isset($_POST['clan_name']) && !empty($_POST['clan_name']) && isset($_POST['clan_name_new']) && !empty($_POST['clan_name_new'])) {
$query_1 = mysql_query ("SELECT `id` FROM `person` WHERE `tribe` = '".addslashes($_POST['clan_name'])."'");
if (mysql_num_rows($query_1)) {
$query_2 = mysql_query ("SELECT `id` FROM `person` WHERE `tribe` = '".addslashes($_POST['clan_name_new'])."'");
if (!mysql_num_rows($query_2)) {
$name = mysql_query("UPDATE `person` SET `tribe` = '".addslashes($_POST['clan_name_new'])."' WHERE `tribe` = '".addslashes($_POST['clan_name'])."'");
print "<FONT class=\"agree\">Клан \"".$_POST['clan_name']."\" успешно изменил название на \"".$_POST['clan_name_new']."\"!</FONT>
";
$query_3 = mysql_query ("SELECT `clan_id` FROM `top` WHERE `clan` = '".addslashes($_POST['clan_name'])."'");
if (mysql_num_rows($query_3)){
$name_top = mysql_query("UPDATE `top` SET `clan` = '".addslashes($_POST['clan_name_new'])."' WHERE `clan` = '".addslashes($_POST['clan_name'])."'");
}
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan_name_new']."\" уже сущесвует!</FONT>"; }
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan_name']."\" не сущесвует!</FONT>"; }
print "
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['clan']=='update') {
if (isset($_POST['clan_name']) && !empty($_POST['clan_name']) && isset($_POST['b_clan_new']) && !empty($_POST['b_clan_new'])) {
$query_1 = mysql_query ("SELECT `id` FROM `person` WHERE `tribe` = '".addslashes($_POST['clan_name'])."'");
if (mysql_num_rows($query_1)) {
$query_2 = mysql_query ("SELECT `id` FROM `person` WHERE `user` = '".addslashes($_POST['b_clan_new'])."'");
if (mysql_num_rows($query_2)) {
$update_old = mysql_query("UPDATE `person` SET `b_tribe` = '0' WHERE `tribe` = '".addslashes($_POST['clan_name'])."' AND `b_tribe` = '1'");
$update = mysql_query("UPDATE `person` SET `tribe` = '".addslashes($_POST['clan_name'])."', `b_tribe` = '1' WHERE `user` = '".addslashes($_POST['b_clan_new'])."'");
print "<FONT class=\"agree\">Клан \"".$_POST['clan_name']."\" успешно изменил Главу. Новый Глава - \"".$_POST['b_clan_new']."\"!</FONT>
";
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['b_clab_new']."\" не найден!</FONT>"; }
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan_name']."\" не сущесвует!</FONT>"; }
print "
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['clan']=='delete') {
if (isset($_POST['clan_name']) && !empty($_POST['clan_name'])) {
$query_1 = mysql_query ("SELECT `id` FROM `person` WHERE `tribe` = '".addslashes($_POST['clan_name'])."'");
if (mysql_num_rows($query_1)){
$delete = mysql_query("UPDATE `person` SET `tribe` = '', `tribe_rank` = '', `b_tribe` = '0' WHERE `tribe` = '".addslashes($_POST['clan_name'])."'");
$delete1 = mysql_query("DELETE FROM `tribes` WHERE `name` = '".addslashes($_POST['clan_name'])."'");
print "<FONT class=\"agree\">Клан \"".$_POST['clan_name']."\" успешно расформирован!</FONT>
";
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan_name']."\" не сущесвует!</FONT>
"; }
$query_2 = mysql_query ("SELECT `clan_id` FROM `top` WHERE `clan` = '".addslashes($_POST['clan_name'])."'");
if (mysql_num_rows($query_2)){
$delete = mysql_query("DELETE FROM `top` WHERE `clan` = '".addslashes($_POST['clan_name'])."'");
print "<FONT class=\"agree\">Клан \"".$_POST['clan_name']."\" успешно удален из рейтинга!</FONT>
";
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan_name']."\" не найден в рейтинге!</FONT>
"; }
print "
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['clan']=='show') {
if (isset($_POST['clan_name']) && !empty($_POST['clan_name'])) {
$query_1 = mysql_query ("SELECT `user`,`tribe_rank`,`b_tribe` FROM `person` WHERE `tribe` = '".addslashes($_POST['clan_name'])."'");
$kol = mysql_num_rows($query_1);
if ($kol>0){
print "<FONT class=agree>Просмотр состава клана \"".$_POST['clan_name']."\"</FONT>
<TABLE width=50% cellpadding=3 cellspacing=1 border=1 bordercolor=#CCCCCC><TR><TD width=50% align=center>[b][u]Персонаж[/u][/b]</TD><TD width=50% align=center>[b][u]Статус[/u][/b]</TD></TR>";
for ($i=0; $i<$kol; $i++) {
$arr = mysql_fetch_array($query_1);
print "<TR>";
print "<TD align=center>[B]".$arr['user']."[/B]</TD>";
print "<TD align=center>";
if ($arr['b_tribe']==1) print "<FONT color=RED>[b]Глава клана[/b]</FONT>";
else { print "[B]".$arr['tribe_rank']."[/B]"; if ($arr['b_tribe']==2) print " <FONT color=green>(права на прием)</FONT>"; }
print "</TD>";
print "</TR>";
}
print "</TABLE>";
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan_name']."\" не сущесвует!</FONT>
"; }
print "
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['clan']=='add_user') {
if (isset($_POST['user']) && !empty($_POST['user']) && isset($_POST['clan_name']) && !empty($_POST['clan_name'])) {
$query_1 = mysql_query ("SELECT `tribe` FROM `person` WHERE `user` = '".addslashes($_POST['user'])."'");
if (mysql_num_rows($query_1)){
$arr = mysql_fetch_array ($query_1);
if ($arr['tribe']=="" or $arr['tribe']==" ") {
$query_2 = mysql_query ("SELECT `id` FROM `person` WHERE `tribe` = '".addslashes($_POST['clan_name'])."'");
if (mysql_num_rows($query_2)){
$add_user = mysql_query("UPDATE `person` SET `tribe` = '".addslashes($_POST['clan_name'])."', `tribe_rank` = '', `b_tribe` = '0' WHERE `user` = '".addslashes($_POST['user'])."'");
print "<FONT class=\"agree\">Персонаж \"".$_POST['user']."\" успешно принят в клан \"".$_POST['clan_name']."\"!</FONT>
";
} else { print "<FONT class=\"bloked\">Клан \"".$_POST['clan_name']."\" не сущесвует!</FONT>
"; }
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['user']."\" уже состоит в клане \"".$arr['tribe']."\"!</FONT>
"; }
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['user']."\" не найден!</FONT>
"; }
print "
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['clan']=='del_user') {
if (isset($_POST['user']) && !empty($_POST['user'])) {
$query_1 = mysql_query ("SELECT `id` FROM `person` WHERE `user` = '".addslashes($_POST['user'])."'");
if (mysql_num_rows($query_1)){
$del_user = mysql_query("UPDATE `person` SET `tribe` = '', `tribe_rank` = '', `b_tribe` = '0' WHERE `user` = '".addslashes($_POST['user'])."'");
print "<FONT class=\"agree\">Персонаж \"".$_POST['user']."\" успешно исключен из клана!</FONT>
";
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['user']."\" не найден!</FONT>
"; }
print "
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['clan']=='add_b') {
if (isset($_POST['user']) && !empty($_POST['user'])) {
$query_1 = mysql_query ("SELECT `tribe` FROM `person` WHERE `user` = '".addslashes($_POST['user'])."'");
if (mysql_num_rows($query_1)){
$arr = mysql_fetch_array ($query_1);
if ($arr['tribe']<>"" or $arr['tribe']<>" ") {
$add_b = mysql_query("UPDATE `person` SET `b_tribe` = '2' WHERE `user` = '".addslashes($_POST['user'])."'");
print "<FONT class=\"agree\">Персонажу \"".$_POST['user']."\" успешно даны права на прием / изменение статуса!</FONT>
";
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['user']."\" не состоит в клане!</FONT>
"; }
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['user']."\" не найден!</FONT>
"; }
print "
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['clan']=='del_b') {
if (isset($_POST['user']) && !empty($_POST['user'])) {
$query_1 = mysql_query ("SELECT `tribe` FROM `person` WHERE `user` = '".addslashes($_POST['user'])."'");
if (mysql_num_rows($query_1)){
$arr = mysql_fetch_array ($query_1);
if ($arr['tribe']<>"" or $arr['tribe']<>" ") {
$add_b = mysql_query("UPDATE `person` SET `b_tribe` = '0' WHERE `user` = '".addslashes($_POST['user'])."'");
print "<FONT class=\"agree\">У персонажа \"".$_POST['user']."\" успешно отобраны права на прием / изменение статуса!</FONT>
";
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['user']."\" не состоит в клане!</FONT>
"; }
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['user']."\" не найден!</FONT>
"; }
print "
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
elseif ($_GET['clan']=='upd_rank') {
if (isset($_POST['user']) && !empty($_POST['user']) && isset($_POST['rank_new'])) {
$query_1 = mysql_query ("SELECT `tribe` FROM `person` WHERE `user` = '".addslashes($_POST['user'])."'");
if (mysql_num_rows($query_1)){
$arr = mysql_fetch_array ($query_1);
if ($arr['tribe']<>"" or $arr['tribe']<>" ") {
$add_b = mysql_query("UPDATE `person` SET `tribe_rank` = '".addslashes($_POST['rank_new'])."' WHERE `user` = '".addslashes($_POST['user'])."'");
print "<FONT class=\"agree\">Персонажу \"".$_POST['user']."\" успешно присвоено звание \"".$_POST['rank_new']."\" в клане \"".$arr['tribe']."\"!</FONT>
";
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['user']."\" не состоит в клане!</FONT>
"; }
} else { print "<FONT class=\"bloked\">Персонаж \"".$_POST['user']."\" не найден!</FONT>
"; }
print "
<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">";
} else { print "<INPUT TYPE=button CLASS=input VALUE=\"Назад\" STYLE='width=150' ONCLICK=\"window.location='admin.php'\">"; }
}
else {
if (isset($_GET['top'])) { print "<CENTER><FONT class=title>Управление рейтингом кланов</FONT>
"; }
?>
<CENTER><FONT class=title>Управление рейтингом кланов</FONT>
<TABLE width="90%" align="center" cellpadding="3" cellspacing="3" border="0">
<TR>
<TD width="33%" valign="top">
<FIELDSET>
<LEGEND><small class=ch>Добавить клан в рейтинг</small></LEGEND>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?top=add&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Клан:</TD>
<TD width="50%"><INPUT size="25" class="input" name="clan"></TD>
</TR>
<TR>
<TD>Адрес сайта:</TD>
<TD><INPUT size="25" class="input" name="url"></TD>
</TR>
<TR>
<TD>Описание:</TD>
<TD><INPUT size="25" class="input" name="about"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Добавить клан в рейтинг"></TD>
</TR>
</FORM>
</TABLE>
</FIELDSET>
</TD>
<TD width="33%" valign="top">
<FIELDSET>
<LEGEND><small class=ch>Редактировать клан в рейтинге</small></LEGEND>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?top=edit&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Клан:</TD>
<TD width="50%"><INPUT size="25" class="input" name="clan"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Редактировать клан в рейтинге"></TD>
</TR>
</FORM>
</TABLE>
</FIELDSET>
</TD>
<TD width="33%" valign="top">
<FIELDSET>
<LEGEND><small class=ch>Удалить клан из рейтинга</small></LEGEND>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?top=delete&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Клан:</TD>
<TD width="50%"><INPUT size="25" class="input" name="clan"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Удалить клан из рейтинга"></TD>
</TR>
</FORM>
</TABLE>
</FIELDSET>
</TD>
</TR>
<TR>
<TD align="center" colspan="3"><CENTER><FONT class=title>Управление кланами</FONT>
</TD>
</TR>
<TR>
<TD width="33%" valign="top">
<FIELDSET>
<LEGEND><small class=ch>Создать клан</small></LEGEND>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?clan=create&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Имя клана(англ):</TD>
<TD width="50%"><INPUT size="25" class="input" name="clan_name"></TD>
</TR>
<TR>
<TD width="50%">Название клана:</TD>
<TD width="50%"><INPUT size="25" class="input" name="name_short"></TD>
</TR>
<TR>
<TD>Глава:</TD>
<TD><INPUT size="25" class="input" name="b_clan"></TD>
</TR>
<TR>
<TD>Адрес сайта:</TD>
<TD><INPUT size="25" class="input" name="url"></TD>
</TR>
<TR>
<TD>Описание:</TD>
<TD><INPUT size="25" class="input" name="about"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Создать клан"></TD>
</TR>
</FORM>
</TABLE>
</FIELDSET>
</TD>
<TD width="33%" valign="top">
<FIELDSET>
<LEGEND><small class=ch>Редактировать клан</small></LEGEND>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?clan=name&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Клан:</TD>
<TD width="50%"><INPUT size="25" class="input" name="clan_name"></TD>
</TR>
<TR>
<TR>
<TD width="50%">Новое название:</TD>
<TD width="50%"><INPUT size="25" class="input" name="clan_name_new"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Изменить название клана"></TD>
</TR>
</FORM>
</TABLE>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?clan=update&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Клан:</TD>
<TD width="50%"><INPUT size="25" class="input" name="clan_name"></TD>
</TR>
<TR>
<TD width="50%">Новый Глава:</TD>
<TD width="50%"><INPUT size="25" class="input" name="b_clan_new"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Изменить Главу клана"></TD>
</TR>
</FORM>
</TABLE>
</FIELDSET>
</TD>
<TD width="33%" valign="top">
<FIELDSET>
<LEGEND><small class=ch>Расформировать клан</small></LEGEND>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?clan=delete&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Клан:</TD>
<TD width="50%"><INPUT size="25" class="input" name="clan_name"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Расформировать клан"></TD>
</TR>
</FORM>
</TABLE>
</FIELDSET>
</TD>
</TR>
<TR>
<TD width="33%" valign="top">
<FIELDSET>
<LEGEND><small class=ch>Состав клана</small></LEGEND>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?clan=show&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Клан:</TD>
<TD width="50%"><INPUT size="25" class="input" name="clan_name"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Посмотреть"></TD>
</TR>
</FORM>
</TABLE>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?clan=add_user&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Клан:</TD>
<TD width="50%"><INPUT size="25" class="input" name="clan_name"></TD>
</TR>
<TR>
<TD width="50%">Персонаж:</TD>
<TD width="50%"><INPUT size="25" class="input" name="user"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Принять в клан"></TD>
</TR>
</FORM>
</TABLE>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?clan=del_user&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Персонаж:</TD>
<TD width="50%"><INPUT size="25" class="input" name="user"></TD>
</TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Исключить из клана"></TD>
</TR>
</FORM>
</TABLE>
</FIELDSET>
</TD>
<TD width="33%" valign="top">
<FIELDSET>
<LEGEND><small class=ch>Права на прием / изменение статуса</small></LEGEND>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?clan=add_b&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Персонаж:</TD>
<TD width="50%"><INPUT size="25" class="input" name="user"></TD>
</TR>
<TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Дать права"></TD>
</TR>
</FORM>
</TABLE>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?clan=del_b&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Персонаж:</TD>
<TD width="50%"><INPUT size="25" class="input" name="user"></TD>
</TR>
<TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Убрать права"></TD>
</TR>
</FORM>
</TABLE>
</FIELDSET>
</TD>
<TD width="33%" valign="top">
<FIELDSET>
<LEGEND><small class=ch>Звание персонажа в клане</small></LEGEND>
<TABLE width="90%" align="center" cellpadding="2" cellspacing="2">
<FORM action="admin.php?clan=upd_rank&tmp=<?=time()?>" name="add" method="post">
<TR>
<TD width="50%">Персонаж:</TD>
<TD width="50%"><INPUT size="25" class="input" name="user"></TD>
</TR>
<TR>
<TD width="50%">Новое звание:</TD>
<TD width="50%"><INPUT size="25" class="input" name="rank_new"></TD>
</TR>
<TR>
<TR>
<TD align="center" colspan="2"><INPUT type="submit" class="input" value="Изменить звание"></TD>
</TR>
</FORM>
</TABLE>
</FIELDSET>
</TD>
</TR>
</TABLE>
<?
}
?>
</BODY>