• Модуль: catalog
  • Путь к файлу: ~/bitrix/modules/catalog/lib/ebay/exportoffer.php
  • Класс: BitrixCatalogEbayExportOffer
  • Вызов: ExportOffer::getPictureUrl
protected function getPictureUrl($pictNo)
{
	$strFile = "";

	if ($file = CFile::GetFileArray($pictNo))
	{
		if(mb_substr($file["SRC"], 0, 1) == "/")
			$strFile = "http://".$this->arIblock['SERVER_NAME'].implode("/", array_map("rawurlencode", explode("/", $file["SRC"])));
		elseif(preg_match("/^(http|https):\/\/(.*?)\/(.*)$/", $file["SRC"], $match))
			$strFile = "http://".$match[2].'/'.implode("/", array_map("rawurlencode", explode("/", $match[3])));
		else
			$strFile = $file["SRC"];
	}

	return $strFile;
}