• Модуль: main
  • Путь к файлу: ~/bitrix/modules/main/classes/general/component_template.php
  • Класс: CBitrixComponentTemplate
  • Вызов: CBitrixComponentTemplate::GetCachedData
public function GetCachedData()
{
	if (!$this->__bInited)
		return null;

	$arReturn = array();

	if($this->__folder <> '')
	{
		$fname = $_SERVER["DOCUMENT_ROOT"].$this->__folder."/style.css";
		if (file_exists($fname))
			$arReturn["additionalCSS"] = $this->__folder."/style.css";

		$fname = $_SERVER["DOCUMENT_ROOT"].$this->__folder."/script.js";
		if (file_exists($fname))
			$arReturn["additionalJS"] = $this->__folder."/script.js";
	}

	if (!empty($this->frames))
	{
		$arReturn["frames"] = array();
		foreach ($this->frames as $frame)
		{
			$arReturn["frames"][] = $frame->getCachedData();
		}
	}

	$arReturn["frameMode"] = $this->frameMode;
	if (!$this->frameMode)
	{
		$arReturn["frameModeCtx"] = $this->__file;
	}

	if ($this->externalCss)
	{
		$arReturn["externalCss"] = $this->externalCss;
	}

	if ($this->externalJs)
	{
		$arReturn["externalJs"] = $this->externalJs;
	}

	return $arReturn;
}