Вход Регистрация
Файл: system/controllers/search/hooks/content_before_item.php
Строк: 19
<?php

class onSearchContentBeforeItem extends cmsAction {

    public function 
run($data){

        if(empty(
$this->options['is_hash_tag'])){ return $data; }

        list(
$ctype$item$fields) = $data;

        foreach (
$fields as $field) {

            if(!
in_array($field['type'], array('text''html')) || empty($field['options']['in_fulltext_search'])){
                continue;
            }

            if(!empty(
$item[$field['name']])){
                
$fields[$field['name']]['html'] = $this->parseHashTag($field['html']);
            }

        }

        return array(
$ctype$item$fields);

    }

}
Онлайн: 1
Реклама