Файл: modules/pages/smiles.php
Строк: 36
<?php
/**
* Licensed under The MIT License
* For full copyright and license information, please see the LICENSE.txt
* Redistributions of files must retain the above copyright notice.
*
* @copyright Copyright (c) 2013, Taras Chornyi, Sergiy Mazurenko, Ivan Kotliar
* @link http://perf-engine.net
* @package PerfEngine
* @license http://www.opensource.org/licenses/mit-license.php MIT License
*/
$locate = 'in_faq';
$title = _t('smiles');
include_header($title);
Template::div('title', _t('smiles'));
$smiles_cat = $db->query("SELECT * FROM `smiles` WHERE `type` = '0'")->rowCount();
$pages = new Paginator($smiles_cat, $ames);
if($smiles_cat == 0)
{
Template::div('menu', _t('dl_dir_empty'));
}
else
{
$cat = $db->query("SELECT * FROM `smiles` WHERE `type` = '0' ORDER BY id ASC LIMIT $start, $ames");
foreach($cat as $cats)
{
Template::div('menu', img('smiley-smile.png') .'<a href="/pages/smiles_cat/'. $cats['id'] .'">'. _t($cats['name']) .'</a> ('.$db->query("SELECT * FROM `smiles` WHERE `cat` = '". $cats['id'] ."' AND `type` = '1'")->rowCount().')');
}
$pages->view();
}
Template::div('block', NAV .'<a href="/pages/faq">'. _t('faq').'</a></br/>'. HICO .'<a href="/">'. _t('home').'</a>');
include_footer();
?>