<?if(!defined("B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED!==true)die();
foreach($arResult["ITEMS"] as $key => $arItem) {
if(is_array($arItem["DETAIL_PICTURE"]))
{
$arFileTmp = CFile::ResizeImageGet(
$arItem["DETAIL_PICTURE"],
array("width" => 100, 'height' => 100),
BX_RESIZE_IMAGE_PROPORTIONAL,
false
);
$arSize = getimagesize($_SERVER["DOCUMENT_ROOT"].$arFileTmp["src"]);
$arResult["ITEMS"][$key]['DETAIL_PICTURE'] = array(
'SRC' => $arFileTmp["src"],
'WIDTH' => IntVal($arSize[0]),
'HEIGHT' => IntVal($arSize[1]),
);
}
}
?> |