GetPropertyEnum
CDBResult CIBlockProperty::GetPropertyEnum( mixed PROP_ID, array arOrder = Array("SORT"=>"asc"), array arFilter = Array() )
Returns filtered and sorted variants of the LIST property value.
Parameters
Parameter | Description |
---|---|
PROP_ID | Numerical or mnemonic property identifier. |
arOrder | Optional sort order. Array of the format Array(by1=>order1[,
by2=>order2 [, ..]]) where by is the field for
sorting. The field can have the following values:
|
arFilter | An array of the format Array("filtering
field"=>"value" [, ...]) where the "filtering
field" can be the following:
|
Return Values
Returns an instance of CDBResult, containing records of the property variant fields.See Also
Example
<? $db_enum_list = CIBlockProperty::GetPropertyEnum("IMPORTANT_NEWS", Array(), Array("IBLOCK_ID"=>$BID, "VALUE"=>"Yes")); if($ar_enum_list = $db_enum_list->GetNext()) { $db_important_news = CIBlockElement::GetList(Array(), Array("IBLOCK_ID"=>$BID, "PROPERTY"=> array("IMPORTANT_NEWS"=> $ar_enum_list["ID"]))); } ?>
© «Bitrix24», 2001-2024