• Модуль: main
  • Путь к файлу: ~/bitrix/modules/main/classes/general/xml.php
  • Класс: CDataXMLDocument
  • Вызов: CDataXMLDocument::__toString
public function __toString()
{
	$ret = "<"."?xml";
	if ($this->version <> '')
	{
		$ret .= " version="".$this->version.""";
	}
	if ($this->encoding <> '')
	{
		$ret .= " encoding="".$this->encoding.""";
	}
	$ret .= "?".">";

	if (is_array($this->children))
	{
		foreach ($this->children as $child)
		{
			$ret .= $child->__toString();
		}
	}

	return $ret;
}