Beispiel #1
0
/**
 * Returns a list of the currently active elements of specified information blocks.
 * Checks permissions by default.
 *
 * @param string $lang Site identifier blocks linked to.
 * @param string $type Information blocks type to get blocks from.
 * @param array|string|int $arTypesInc Information block ID or CODE or array of IDs or CODEs to get.
 * @param array|string|int $arTypesExc Information block ID or CODE or array of IDs or CODEs to exclude.
 * @param array $arOrder Order in which elements will be returned.
 * @param int $cnt Maximum count of elements to be returned.
 * @param array $arFilter Filter to be applied
 * @param array $arSelect Fields to return (all if empty or not supplied)
 * @param bool $arGroupBy Fields to group by (none grouping by default), overwrites $arSelect
 *
 * @return CIBlockResult|int
 * @deprecated No longer used by internal code and not recommended.
 */
function GetIBlockElementListExLang($lang, $type, $arTypesInc = array(), $arTypesExc = array(), $arOrder = array("sort" => "asc"), $cnt = 0, $arFilter = array(), $arSelect = array(), $arGroupBy = false)
{
    $filter = _GetIBlockElementListExLang_tmp($lang, $type, $arTypesInc, $arTypesExc, $arOrder, $cnt, $arFilter);
    if (is_array($cnt)) {
        $arNavParams = $cnt;
    } elseif ($cnt > 0) {
        $arNavParams = array("nTopCount" => $cnt);
    } else {
        $arNavParams = false;
    }
    return CIBlockElement::GetList($arOrder, $filter, $arGroupBy, $arNavParams, $arSelect);
}
Beispiel #2
0
function GetIBlockElementCountExLang($lang, $type, $arTypesInc = array(), $arTypesExc = array(), $arOrder = array("sort" => "asc"), $cnt = 0, $arFilter = array())
{
    $filter = _GetIBlockElementListExLang_tmp($lang, $type, $arTypesInc, $arTypesExc, $arOrder, $cnt, $arFilter);
    return CIBlockElement::GetList($arOrder, $filter, true);
}