• Модуль: main
  • Путь к файлу: ~/bitrix/modules/main/lib/web/httpheaders.php
  • Класс: BitrixMainWebHttpHeaders
  • Вызов: HttpHeaders::getContentType
public function getContentType()
{
	$contentType = $this->get("Content-Type");
	if ($contentType !== null)
	{
		$parts = explode(";", $contentType);

		// RFC 2045 says: "The type, subtype, and parameter names are not case-sensitive."
		return strtolower(trim($parts[0]));
	}

	return null;
}