- Модуль: socialnetwork
- Путь к файлу: ~/bitrix/modules/socialnetwork/classes/general/functions.php
- Класс: CSocNetTextParser
- Вызов: CSocNetTextParser::wrap_long_words
function wrap_long_words($text="")
{
if (
$this->MaxStringLen > 0
&& !empty($text)
)
{
$text = str_replace(array(chr(7), chr(8), chr(34), chr(39)), array("", "", chr(7), chr(8)), $text);
$this->matchNum = 1;
$text = preg_replace_callback(
"/(?<=^|>)([^<]+)(?=<|$)/is".BX_UTF_PCRE_MODIFIER,
array($this, "part_long_words_callback"),
$text
);
$text = str_replace(array(chr(7), chr(8)), array(chr(34), chr(39)), $text);
}
return $text;
}