• Модуль: main
  • Путь к файлу: ~/bitrix/modules/main/classes/general/textparser.php
  • Класс: CTextParser
  • Вызов: CTextParser::convertEmoticon
public function convertEmoticon($matches)
{
	$array = array_intersect_key($this->smileReplaces, $matches);
	$replacement = reset($array);
	if (!empty($replacement))
	{
		if (($this->allow['CLEAR_SMILES'] ?? '') == 'Y')
		{
			return $this->convert_emoticon($replacement['code']);
		}
		else
		{
			return $this->convert_emoticon(
				$replacement['code'],
				$replacement['image'],
				$replacement['description'],
				$replacement['width'],
				$replacement['height'],
				$replacement['descriptionDecode'],
				$replacement['imageDefinition']
			);
		}
	}
	return $matches[0];
}