Answer the question
In order to leave comments, you need to log in
How to set up news.detail in Bitrix?
Hello.
I am working on a site managed by Bitrix.
The task is to create an information rubric, display the most viewed articles and all articles on the rubric page. On the subcategory page, you also need to display the most viewed and all, but from this subcategory.
Created an appropriate information block with the desired structure.
Then I placed 2 components on the stati.php page,
namely:
<?
require($_SERVER["DOCUMENT_ROOT"]."/bitrix/header.php");
$APPLICATION->SetTitle("Статьи");
?>
<h1 class="page_title"><?$APPLICATION->ShowTitle()?></h1>
Популярные статьи:
<i>{bitrix:news}</i>
Все статьи:
<i>{bitrix:news.list}</i>
<?require($_SERVER["DOCUMENT_ROOT"]."/bitrix/footer.php");?>
<h1 class="page_title"><?$APPLICATION->ShowTitle()?></h1>
Популярные статьи:
{Текст текущей статьи}
Все статьи:
<i>{bitrix:news.list}</i>
Answer the question
In order to leave comments, you need to log in
Popular articles:
All articles:
Should be derived from the news.php file in the template of the complex component
Replaces it because it is not a physical page of the site, I generate code at the site of the complex component call and replaces only the call to the complex component templates
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question