V
V
Vanes Ri_Lax2015-03-26 20:13:04
CMS
Vanes Ri_Lax, 2015-03-26 20:13:04

How to display the content of the information system in hostcms?

Hello, I'm trying to figure out hostcms. From this article, I understood how to display a list in an information system, for example, as an information system I have news about a city, an element of the info system is actually news, how to make certain news open when clicking on the list?
I can’t find it, I found how to display static documents, but nothing about dynamic pages ...

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
Eugene, 2016-06-13
@Eugeny1987

$Informationsystem_Controller_Show = new Informationsystem_Controller_Show(
        Core_Entity::factory('Informationsystem', 6) // ID информационной системы
      );

      $Informationsystem_Controller_Show
        ->informationsystemItems()
        ->queryBuilder()
        ->clearOrderBy()
        ->orderBy('RAND()');

      $Informationsystem_Controller_Show
        ->xsl(
          Core_Entity::factory('Xsl')->getByName('СписокУслугНаГлавной') // Имя XSL шаблона
        )
        ->groupsMode('none')
        ->itemsForbiddenTags(array('text'))
        ->group(FALSE)
        ->limit(2) // сколько выводить элементов
        ->show();

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question