<?php if ($text_agree) { ?>
<div class="buttons">
<div class="text-center">
<label><?php echo $text_agree; ?>
<?php if ($agree) { ?>
<input type="checkbox" name="agree" value="1" checked="checked" />
<?php } else { ?>
<input type="checkbox" name="agree" value="1" checked="checked" />
<?php } ?>
</label>
<br />
<br />
<!-- Скрытые поля для AMO -->
<input type="hidden" name="UTM_SOURCE" value="<?php echo $_GET['utm_source']?>">
<input type="hidden" name="UTM_CONTENT" value="<?php echo $_GET['utm_source']?>">
<input type="button" value="<?php echo $button_order; ?>" id="button-order" data-loading-text="<?php echo $text_loading; ?>" class="btn btn-success btn-lg" />
</div>
<div class="catalog-detail__gallery catalog-detail__gallery--454px catalog-detail__gallery--vertical swipeignore image-list__link">
<div class="catalog-detail__gallery-wrapper">
<div class="sticker sticker--upper">
[[*product_new:is=`Да`:then=`<div><div class="sticker__item sticker_item--new font_9">Новинка</div></div>`]]
[[*product_fav:is=`Да`:then=`<div><div class="sticker__item sticker_item--recommend font_9">Рекомендуем</div></div>`]]
[[*product_pop:is=`Да`:then=`<div><div class="sticker__item sticker_item--hit font_9">Хит</div></div>`]]
[[*product_sale:is=`Да`:then=`<div><div class="sticker__item sticker_item--sale font_9">Акция</div></div>`]]
</div>
<div class="catalog-detail__gallery-slider">
[[!ms2Gallery]]
</div>
</div>
</div>
use Bitrix\Main\Loader;
$sectionId = $item['~IBLOCK_SECTION_ID'] ?: $item['IBLOCK_SECTION_ID'] ?: 0;
$sectionName = '';
if (Loader::includeModule('iblock') && $item['~IBLOCK_SECTION_ID'] > 0) {
$section = CIBlockSection::GetByID($item['~IBLOCK_SECTION_ID'])->Fetch();
if ($section) {
$sectionName = $section['NAME'];
} else {
$sectionName = 'Раздел не найден';
}
} else {
$sectionName = 'Раздел не указан';
}
<span class="product-card__category">
<?php echo $sectionId; ?>
<?php echo $sectionName; ?>
</span>