{% if newsBoxesStories is defined and not newsBoxesStories is empty %} {{ render(controller('App\\Controller\\DefaultController::slider', {'boxNews':newsBoxesStories} )) }} {% endif %} {% if newsBoxes is defined and not newsBoxes is empty %} {% for key,newsBox in newsBoxes %}
{{ newsBox|raw }}
{{ ads.printAd('desktop', 'boxes_ad', key)|raw }} {% endfor %} {% endif %} {% set evenIndex = 1 %} {% set adIndex = 0 %} {% if subCategories is defined and subCategories and not ajax %}
{% endif %} {% if not newsArray is empty %} {% for key,news in newsArray %}
{% if news.video %} {% endif %} {{ news.picture }} {{ news.title|raw }} {% if is_protected is defined and is_protected %} hits:{{ news.hits }} {% endif %}
{% if key == 5 and not ajax and allNewsBoxesStories is defined and not allNewsBoxesStories is empty %}
{{ render(controller('App\\Controller\\DefaultController::slider', {'boxNews':allNewsBoxesStories} )) }}
{% endif %} {% if ads is defined and ads and ((evenIndex == 1 and (key + 1)%5 == 0 and (key + 1) / 5 > adIndex) or (evenIndex == 0 and key % 5 == 0 and key / 5 > adIndex)) and key > 0 %} {% if evenIndex == 1 %} {% set adIndex = (key + 1) / 5 %} {% set evenIndex = 0 %} {% else %} {% set adIndex = key / 5 %} {% set evenIndex = 1 %} {% endif %}
{{ ads is not null ? ads.printAd('desktop', 'newsfeed', adIndex)|raw : '' }}
{{ ads is not null ? ads.printAd('mobile', 'newsfeed', adIndex)|raw : '' }}
{% endif %} {% endfor %} {% if readMore is defined and readMore %}
{{ '_FOR_MORE_CLICK_HERE_'|trans }}
{% endif %} {% elseif (not ajax is defined) or (ajax is defined and not ajax) %}
{{ '_NO_NEWS_RESULTS_'|trans }}
{% endif %}