Файл: public_html/modules/downloads/new_files.php
Строк: 35
<?php
/**********************************
* @package: PerfCMS *
* @year: 2012 *
* @author: Artas *
* @link: http://perfcms.net *
* ------------------------------- *
* @package: PerfCMS Ultra *
* @year: 2013 *
* @author: wanya26ua & Tesla *
* @link: http://perfclub.ru *
**********************************/
$locate = 'in_downloads';
$title = $lang->word('new_files').' | '.$lang->word('downloads');
require_once(SYS.'/view/header.php');
$tpl->div('title', $lang->word('new_files').' | '.$lang->word('downloads'));
$files_r = $db->query("SELECT * FROM `downloads_files` WHERE `time` > '". (time()-60*60*24) ."'")->rowCount();
$pages = new Paginator($files_r, $ames);
if($files_r == 0) {
echo $tpl->div('menu', $lang->word('no_files'));
}
else {
$files_q = $db->query("SELECT * FROM `downloads_files` WHERE `time` > '". (time()-60*60*24) ."' ORDER BY time DESC LIMIT $start, $ames");
while($files = $files_q->fetch()) {
echo '<div class="menu">
'.dlext($files['ext']).'
<a href="/downloads/file/'. $files['id'] .'">'. $files['name'] .' ('.$files['ext'].')</a> ['.size($files['size']).']<br/>
'. mb_substr($files['description'], 0, 100).'...
</div>';
}
$pages->view('/downloads/new_files/?');
}
$tpl->div('block', NAV . ' <a href="/downloads/">'. $lang->word('downloads') .'</a><br/>' . HICO .' <a href="/">'. $lang->word('home') .'</a>');
require_once(SYS.'/view/footer.php');
?>