Файл: obmen/inc/obmen-act.tpl
Строк: 38
<?
$obmen_s = mysql_fetch_assoc(mysql_query("SELECT * FROM
`obmen-s` WHERE `id` = '1'"));
if($obmen_s['in-t']==0){
$total =
mysql_result(mysql_query("SELECT COUNT(*) FROM `obmen-f` WHERE `date`
> '".(time()-86400)."'"), 0);
if ($total!=0){
echo
'<div class="main-text">Новые файлы
обенника</div>';
$obmen_f_c = mysql_query("SELECT *
FROM `obmen-f` WHERE `date` > '".(time()-86400)."' ORDER BY
`date` DESC LIMIT ".$obmen_s['in']."");
while ($obmen_f =
mysql_fetch_assoc($obmen_f_c)){
$o_f_new =
mysql_result(mysql_query("SELECT COUNT(*) FROM `obmen-f` WHERE `id` =
'".int($obmen_f['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="/obmen/file-'.int($obmen_f['id']).'.dll"
title="'.$obmen_f['name'].'">';
if
(file_exists('./obmen/type/'.$obmen_f['type'].'.tpl')){
iconsob(''.$obmen_f['type'].'');
}else{
iconsob('file');
}
echo
''.$obmen_f['file'].'.'.$obmen_f['type'].'';
echo '</td>';
echo
'<td class="apa-r">';
if ($o_f_new!=0)icons('new');
if
($o_f_new==0)echo
'<time>'.vtime($obmen_f['date']).'</time>';
echo
'</td></tr>';
echo '</table>';
echo
'</div>';
}
}
}
?>