Answer the question
In order to leave comments, you need to log in
How to display the xml_id of the selected property value of the list type?
Hello.
Infoblock elements are displayed on the page, each has a property of the list type and one of the values is selected, how to get exactly the selected value? Found only how to get a list of all options.
Answer the question
In order to leave comments, you need to log in
If the version of Bitrix is later than autumn 2019, then it is possible through ORM
$iblock = \Bitrix\Iblock\Iblock::wakeUp(9);
$elements = $iblock->getEntityDataClass()::getList(
[
'filter' => ['ID' => 28770],
'select' => ['ID', 'C_CATALOG_LABELS']
]
)->fetch();
\Bitrix\Main\Diag\Debug::dump($elements);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question