25 lines
540 B
PHP
25 lines
540 B
PHP
|
<?php
|
||
|
|
||
|
require _MODULE_DIR_.'/cmsps/cmsps.php';
|
||
|
|
||
|
class SearchController extends SearchControllerCore
|
||
|
{
|
||
|
public function initContent()
|
||
|
{
|
||
|
parent::initContent();
|
||
|
|
||
|
if (($query = Tools::getValue('search_query', Tools::getValue('ref'))) && !is_array($query)) {
|
||
|
|
||
|
$posts = CmsPsPost::search($query, 15, $this->context->language->id);
|
||
|
$editos = CmsPsEdito::search($query, 15, $this->context->language->id);
|
||
|
|
||
|
$this->context->smarty->assign(array(
|
||
|
'posts' => $posts,
|
||
|
'editos' => $editos,
|
||
|
'test' => 'test'
|
||
|
));
|
||
|
}
|
||
|
}
|
||
|
|
||
|
}
|