Answer the question
In order to leave comments, you need to log in
How to set random sorting in arrfilter?
I take out
$arSelect = array("ID", "NAME", "PREVIEW_TEXT", "DETAIL_PAGE_URL",'PREVIEW_PICTURE', "PROPERTY_*");
$arFilter = array("IBLOCK_ID" => 10, "ACTIVE" => "Y", 'ID' => $SEORES['SEO']['VALUE']);
$res = CIBlockElement::GetList(array(), $arFilter, false, array("nPageSize" => 50), $arSelect);
Answer the question
In order to leave comments, you need to log in
arrfilter is only used to filter data i.e. weeding out excess.
You need to sort through arOrder (first argument)
$res = CIBlockElement::GetList(array("rand" => "asc"), $arFilter, false, array("nPageSize" => 50), $arSelect);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question