Answer the question
In order to leave comments, you need to log in
Bitrix.Chain navigation?
There is a complex catalog component, it has 2 components - product card in detail and breadcrumb
A path is formed in breadcrumbs
$strReturn .= '<div class="bx-breadcrumb">';
$itemSize = count($arResult);
for($index = 0; $index < $itemSize; $index++)
{
$title = htmlspecialcharsex($arResult[$index]["TITLE"]);
$nextRef = ($index < $itemSize-2 && $arResult[$index+1]["LINK"] <> ""? ' itemref="bx_breadcrumb_'.($index+1).'"' : '');
$child = ($index > 0? ' itemprop="child"' : '');
$arrow = ($index > 0? '<i class="fa fa-angle-right"></i>' : '');
if($arResult[$index]["LINK"] <> "" && $index != $itemSize-1)
{
}
else
{
$strReturn .= '
<ul class="crumbs">
<li><a href="/index.php">Главная</a></li> <li><a href="'.$arResult[$index]["LINK"].'">'.$title.'</a></li> <li><a href="/catalog/secondhand">Подержаные погрузчики</a></li>
</ul>';
}
}
<?=$arResult['NAME']?>
Answer the question
In order to leave comments, you need to log in
Add crumbs code:
Paste this code into the template you need.
More details: https://dev.1c-bitrix.ru/api_help/main/reference/c...
Array
(
[0] => Array
(
[TITLE] => Каталог
[LINK] => /catalog/
)
)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question