Documentation

strings

The following functions are used to process strings and text:

MethodDescription Available from version
TxtToHTML Converts plain text to HTML formatted text.
HTMLToTxt Converts the original HTML code to plain text by deleting tags or replacing them with the equivalent text format.
TruncateText Truncates the specified string to the maximum length of max_length. If a string is truncated, ellipsis are added.
InsertSpaces Splits long words in a text. Returns the text containing words of the specified length.
RandString Returns a string of the specified length consisting of random symbols.
ToUpper Converts symbols of the original string to uppercase.
ToLower Converts the symbols of the original string to lowercase.
htmlspecialcharsEx Converts text to HTML safe format, replacing special symbols with the corresponding HTML entities.
htmlspecialcharsBack Converts text from HTML safe format to the human-readable form.
utf8win1251 Converts a string from UTF-8 to Windows-1251.
TrimEx Deletes a character in the string from the specified side.
TrimExAll Deletes all right- and left-most characters.
Bxstrrpos Returns the position of the last string occurrence.
CheckSerializedData Check of serialized string validity.


© «Bitrix24», 2001-2022
Up