<?
include_once '../sys/inc/start.php';
include_once '../sys/inc/compress.php';
include_once '../sys/inc/sess.php';
include_once '../sys/inc/home.php';
include_once '../sys/inc/settings.php';
include_once '../sys/inc/db_connect.php';
include_once '../sys/inc/ipua.php';
include_once '../sys/inc/fnc.php';
include_once '../sys/inc/user.php';
$set['title']='Новости';
include_once '../sys/inc/thead.php';
title();
err();
if (isset($_GET['id']) && is_numeric($_GET['id']) && $_GET['id']!=NULL)
{
$id_list=mysql_fetch_array(mysql_query("SELECT * FROM `news` WHERE `id` = ".intval($_GET['id'])." LIMIT 1"));

$ank=mysql_fetch_assoc(mysql_query("SELECT * FROM `user` WHERE `id` = ".intval($_GET['id'])." LIMIT 1"));
echo "<table class='post'>\n";
echo '<tr><td class="gicon">';
echo "<img src='/style/icon36/news.png' alt='' class='icon'/>\n";
echo '</td><td class="menu_razd">';
echo "<font color='#2d2b2c'>$id_list[title]</font>\n";
echo " <font color='#f99acb'>(".vremja($id_list['time']).")</font><br/>\n";
echo "<font color='#504a4b'>Комментарии <b>".mysql_result(mysql_query("SELECT COUNT(*) FROM `news_komm` WHERE `id_news` = '$id_list[id]'"),0)."</b></font><br />\n";
echo '</td></tr>';
echo '</table>';
echo '<div class="theme"><font color="#504a4b">';
echo trim(br(bbcode(smiles(links(stripcslashes(htmlspecialchars($id_list['msg'])))))))."<br />\n";
if ($id_list['link']!=NULL)echo "<a href='$id_list[link]'><u>Подробности</u></a><br />\n";
echo '</font></div>';
}
echo '<div class="linechat"></div>';

include_once '../news/komm.php';
echo "<div class='foot'>\n";
echo "<a href='/news'>Новости</a><br />\n";
echo "</div>\n";
include_once '../sys/inc/tfoot.php';

?>