Файл: forum/adm.php
Строк: 60
<?php
require_once '../sys/inc/start.php';
require_once '../sys/inc/compress.php';
require_once '../sys/inc/sess.php';
require_once '../sys/inc/settings.php';
require_once '../sys/inc/db_connect.php';
require_once '../sys/inc/ipua.php';
require_once '../sys/inc/fnc.php';
require_once '../sys/inc/user.php';
$set['title'] = 'Форум - Жалобы';
require_once '../sys/inc/thead.php';
aut();
$k_post = mysql_result(mysql_query("SELECT COUNT(*) FROM `forum_zhal`"), 0);
$k_page = k_page($k_post, $set['p_str']);
$page = page($k_page);
$start = $set['p_str'] * $page - $set['p_str'];
$q = mysql_query("SELECT * FROM `forum_zhal` ORDER BY `id` DESC LIMIT $start, $set[p_str]");
if (mysql_num_rows($q) == 0) {
echo "<table class = 'foot'><tr><td class = 'null'>";
echo "<img src = '/style/icons/bullet_error.png' /> Нет результатов";
echo "</td></tr></table>";
}
while ($them = mysql_fetch_assoc($q)) {
$forum = mysql_fetch_assoc(mysql_query("SELECT * FROM `forum_f` WHERE `id` = '$them[id_forum]' LIMIT 1"));
$id_post = mysql_fetch_assoc(mysql_query("SELECT * FROM `forum_p` WHERE `id` = '$them[id_post]' LIMIT 1"));
$razdel = mysql_fetch_assoc(mysql_query("SELECT * FROM `forum_r` WHERE `id` = '$them[id_razdel]' LIMIT 1"));
$them = mysql_fetch_assoc(mysql_query("SELECT * FROM `forum_t` WHERE `id` = '$them[id_them]' LIMIT 1"));
$ank = mysql_fetch_assoc(mysql_query("SELECT * FROM `user` WHERE `id` = $id_post[id_user] LIMIT 1"));
$ank2 = mysql_fetch_assoc(mysql_query("SELECT * FROM `user` WHERE `id` = $them[id_user] LIMIT 1"));
echo "<table class = 'foot'><tr><td class = 'null'>";
echo "Жалоба на: ";
echo "<a href = '/info.php?id=$ank[id]'>";
echo text::gradient("$ank[nick]", "$ank[ncolor]", "$ank[ncolor2]");
echo "</a> ";
if ($ank['level'] < $user['level']) {
echo " | <a href='/adm_panel/banf.php?f=$forum[id]&r=$razdel[id]&t=$them[id]&p=$id_post[id]&id=$ank[id]'>Бан</a>n";
}
echo "<br />";
echo output_text($id_post['msg']) . "<br />n";
echo "Жалоба от: ";
echo "<a href = '/info.php?id=$ank2[id]'>";
echo text::gradient("$ank2[nick]", "$ank2[ncolor]", "$ank2[ncolor2]");
echo "</a> <br />";
echo "»<a href='/forum/$forum[id]/$razdel[id]/$them[id]/'>в тему</a> n";
echo "</td></tr></table>";
}
if ($k_page > 1) {
str("?", $k_page, $page);
}
echo "<a href='index.php'><div class='foot'><img src = '/style/icons/left.png' /> Форум</div></a>";
require_once '../sys/inc/tfoot.php';