32 public static function getAvatarSrc($avatarId, $width = 21, $height = 21)
34 static $cache = array();
41 $avatarId = (int) $avatarId;
42 $key = $avatarId .
" $width $height";
44 if (!isset($cache[$key]))
50 $imageFile = \CFile::getFileArray($avatarId);
51 if ($imageFile !==
false)
54 $fileTmp = \CFile::resizeImageGet(
56 array(
"width" => $width,
"height" => $height),
57 BX_RESIZE_IMAGE_EXACT,
60 $src = $fileTmp[
"src"];