Файл: public_html/modules/work/index.php
Строк: 15
<?
/**********************************
* @package: cssliga.ru *
* @year: 2013 *
* @author: AIIeJIbCiH4iK *
* @link: http://cssliga.ru *
* ------------------------------- */
$title = 'Портфолио';
$locate = 'in_portfolio';
require_once(SYS.'/view/header.php');
$tpl->div('title', 'Портфолио');
$tpl->div('menu', '<a href="port">Мое портфолио</a>');
$tpl->div('title', 'Новые портфолио');
$folder = $db->query("SELECT * FROM `portfel` ORDER BY `id` DESC LIMIT 5");
while($fo = $folder->fetch())
{
echo '<div class="post"> '.nick($fo['user']).' | <a href="port?id='.$fo['user'].'">Портфолио</a> ';
echo '</div>';
}
$tpl->div('title', 'Новые работы');
$count_file = $db->query("SELECT * FROM `portfel_work`")->rowCount();
$pages = new Paginator($count_file, 5);
$work = $db->query("SELECT * FROM `portfel_work` ORDER BY `time` DESC LIMIT $start, 5");
while($files = $work->fetch()) {
$mp = $db->query("SELECT * FROM `portfel_scr` WHERE `refid` = '". $files['id'] ."' ORDER BY id LIMIT 1");
echo '<div class="post">';
while($ps = $mp->fetch())
{
echo '<a href="/files/port/'. $ps['url'] .'"><img src="/files/port/'. $ps['url'] .'" alt="" width="60" /></a>';
}
echo '<br /><a href="file?id='.$files['id'].'">'.$files['name'].'</a> ';
echo '</div>';
}
$pages->view('/work/index?');
$tpl->div('block',HICO .'<a href="/">'. $lang->word('home') .'</a>');
require_once(SYS.'/view/footer.php');
?>