Answer the question
In order to leave comments, you need to log in
How to make breadcrumbs work in bitrix?
News > Reviews > News > Reviews - this is displayed on all pages
of the component template code:
<?
if(!defined("B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED!==true)die();
//delayed function must return a string
if(empty($arResult))
return "";
$strReturn = '<ul class="breadcrumb-navigation">';
// echo "<pre>";
// print_r($arResult);
// exit;
for($index = 0, $itemSize = count($arResult); $index < $itemSize; $index++)
{
if($index > 0)
$strReturn .= '<li><span> > </span></li>';
$title = htmlspecialchars($arResult[$index]["TITLE"]);
if($arResult[$index]["LINK"] <> "")
$strReturn .= '<li><a href="'.$arResult[$index]["LINK"].'" title="'.$title.'">'.$title.'</a></li>';
else
$strReturn .= '<li>'.$title.'</li>';
}
$strReturn .= '</ul>';
return $strReturn;
?>
<?$APPLICATION->IncludeComponent("bitrix:breadcrumb","",Array(
"START_FROM" => "0",
"PATH" => "",
"SITE_ID" => "s1"
)
);?>
Answer the question
In order to leave comments, you need to log in
look in the components for options related to INCLUDE_IBLOCK_INTO_CHAIN or something like that. Well, check .sections.php
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question