Файл: obmen/index.php
Строк: 62
<?
include_once('../apahe/ini.php');
$urlup='/obmen/index';
$inc['title'] = 'Обменник';
include_once('../apahe/top.php');
if (!isset($apache)){
header ('location: /input.dll');
exit;
}
$obmen_on = mysql_result(mysql_query("SELECT COUNT(*) FROM `on` WHERE `url` = '/obmen/index'"), 0);
$obmen_s = mysql_fetch_assoc(mysql_query("SELECT * FROM `obmen-s` WHERE `id` = '1'"));
echo '<div class="main-text">';
echo '<a href="on-who.dll" title="В обменнике '.$obmen_on.' чел">В обменнике: '.$obmen_on.' чел</a>';
echo '</div>';
$total = mysql_result(mysql_query("SELECT COUNT(*) FROM `obmen`"), 0);
nav_start($total, $obmen_s[tf]);
if ($total!=0){
$obmen_c = mysql_query("SELECT * FROM `obmen` ORDER BY `date` LIMIT $start, $obmen_s[tf]");
while ($obmen = mysql_fetch_assoc($obmen_c)){
$o_f = mysql_result(mysql_query("SELECT COUNT(*) FROM `obmen-f` WHERE `id-obmen` = '".int($obmen['id'])."'"), 0);
$o_f_new = mysql_result(mysql_query("SELECT COUNT(*) FROM `obmen-f` WHERE `id-obmen` = '".int($obmen['id'])."' and `date` > '".(time()-86400)."'"), 0);
echo '<div class="main-href">';
echo '<table width="100%" cellspacing="0" cellpadding="0">';
echo '<tr><td class="apa-l">';
echo '<a href="folder-'.int($obmen['id']).'.dll" title="'.$obmen['name'].'">';
iconsob('folder');
echo ''.$obmen['name'].'';
echo '</td>';
echo '<td class="apa-r">';
echo '<time>'.$o_f.'';
if ($o_f_new!=0)echo '<new>+'.$o_f_new.'</new>';
echo '</time>';
echo '</td></tr>';
echo '</table>';
echo ''.out($obmen['message']).'';
echo '</div>';
}}else{
error('Папки еще не создавались.');
}
view_nav('/obmen/index.dll?');
include_once('../apahe/bottom.php');
?>