Functions53 public, 1 private

Returns the numbers of bytes required for the provided string using the specified encoding.
publicnumericbyteLen
requiredstringvalue
stringencodingUTF-8
Appends/Prepends the specified character(s) to the provided string until the desired total length is reached.
publicstringcJustify
requiredstringstring
If the final length is odd, the remaining character will be appended.
requiredstringlength
If you specify multiple characters, it will be repeated like a single character.
stringcharacter
Returns if the provided string contains an HTML tag or entity. Self-closing tags are only considered HTML if they are part of the spec.
publicbooleancontainsHtml
requiredstringcontent
Returns the number of matches found for the specified string (needle) in the provided string (haystack).
publicnumericcountMatches
requiredanyhaystack
requiredstringneedle
Counts the number of words found in the provided string. A word is separated by whitespaces or symbols.
publicnumericcountWords
requiredanyinput
Creates a UUID with Base64url encoding. The "short" UUID consists of 22 characters and digits.
publicstringcreateShortUUID
Converts the provided UUID (HEX encoded) to GUID (HEX encoded).
publicstringcreateGUID
stringuuidcreateUUID()
Creates a UUID with HEX encoding and removes the dashes. The UUID consists of 32 uppercase hexadecimal characters.
publicstringcreateUUID
publicbooleanendsWith
requiredanystring
requiredanyvalue
publicbooleanendsWithNoCase
requiredanystring
requiredanyvalue
Corrects the length of the provided string considering the specified minimum/maximum length.
publicstringfixLength
requiredstringsource
numericmin0
numericmax0
stringfill_
Corrects the length of the provided string padding the specified minimum length.
publicstringfixMinLength
requiredstringsource
requirednumericmin
stringfill_
Corrects the length of the provided string truncating the specified maximum length.
publicstringfixMaxLength
requiredstringsource
requirednumericmax
The ellipsis … is placed within the string and will not exceed the maximum.
stringellipsis
Replaces occurences of placeholder marks in the provided string with the specified values in order. Default placeholder mark is: %s
publicstringformat
String that contains placeholder marks to be replaced.
requiredstringsource
Collection of values to replace the placeholder marks in order.
requiredanyvalues
structOPTIONS
optionstringplaceholder%s
if there are more placeholders than values, keep the remaining placeholders
optionbooleankeepRemainingPlaceholdersfalse
how to repeat values in case there are more placeholder marks than values
option"ALL", "LAST", "NONE"repeatArgsNONE
Generates a human friendly sequence of (47) random characters.
publicstringgenerateClearString
Length of the generated sequence.
requirednumericlength
Generates a human friendly sequence of (27) random characters.
publicstringgenerateClearStringNoCase
Length of the generated sequence.
requirednumericlength
Generates a sequence of random characters.
publicstringgenerateRandomString
Length of the generated sequence.
requirednumericlength
Possible characters to appear in the generated sequence.
arraycharacterSet
publicstringgenerateRandomWords
requirednumericcount
stringdelimiter-
Converts the provided HTML content to plain text.
publicstringhtmlToPlain
The HTML content to strip down to plain text.
requiredstringhtml
Allow transforming common elements to their plain representation.
booleantransformtrue
Returns if the provided string is considered as literal for regular expression.
publicstringisReLiteral
requiredanyvalue
Calculates the phonetics for the provided word(s) based on the Cologne phonetics by Hans-Joachim Postel.
publicstringkoelnerPhonetik
Word(s) to calculate the phonetics for.
requiredanyvalue
Calculate words divided by spaces separately.
booleanseparateWordsfalse
Appends the specified character(s) to the provided string until the desired total length is reached.
publicstringlJustify
requiredstringstring
requiredstringlength
If you specify multiple characters, it will be repeated like a single character.
stringcharacter
Removes all obsolete white spaces (tabs, newlines, spaces) in the provided string. Only keeps single spaces.
publicstringminifyString
requiredstringvalue
Normalizes all newlines to linefeed (10) in the provided string.
publicstringnormalizeNewLines
requiredstringsource
Normalizes the provided string by using title case and removing obsolete whitespaces.
publicstringnormalizeString
requiredstringvalue
NONE, COMPANY, PERSONtypeNONE
Pads any digit sequence in the provided string to the specified length
publicstringpadDigits
requiredstringvalue
requirednumericpadding
structOPTIONS{}
option"DIGIT", "NUMERIC"sequenceModeDIGIT
Converts the provided plain text to HTML.
publicstringplainToHtml
requiredstringtext
Visualizes whitespaces in the provided string by replacing non-printable characters into printable characters.
publicstringprintWhitespaces
String that contains the whitespaces to visualize.
requiredstringsource
structwsMap
Prepends the specified character(s) to the provided string until the desired total length is reached.
publicstringrJustify
requiredstringstring
requiredstringlength
If you specify multiple characters, it will be repeated like a single character.
stringcharacter
Escapes the provided string for usage within regular expressions.
publicstringreEscape
requiredstringvalue
Extends ColdFusion's reFindNoCase by accepted data types.
publicnumericreFindNoCase
requiredanyexpression
requiredanydata
Returns the matching groups found in the provided string using the specified regular expression. POSIX: captures all groups (supports lookbehind) JORO: captures first match only (does not support lookbehind)
publicarrayreMatchGroup
requiredstring, Patternregex
requiredstringvalue
"JORO", "POSIX"enginePOSIX
Returns the matching groups found in the provided string using the specified regular expression. POSIX: captures all groups (supports lookbehind) JORO: captures first match only (does not support lookbehind)
publicarrayreMatchGroupNoCase
requiredstringregex
requiredstringvalue
"JORO", "POSIX"enginePOSIX
Replaces the last occurence of the specified string(s) with the provided string.
publicstringreplaceLastOccurenceOf
requiredstringtarget
requiredstring, string[]search
requiredstringreplace
Replaces words (with boundaries left and right) with the provided list of words.
publicstringreplaceWords
requiredstringreplaceIn
requiredarraywordsToReplace
requiredarraywordsToReplaceWith
arrayadditionalBoundaries[]
Invokes the provided callback for each regular expression match in the provided string.
publicstringreReplaceWithCallback
requiredstringvalue
requiredstringregex
requiredfunctioncallback
booleanreturnGroupsfalse
Invokes the provided callback for each regular expression match in the provided string.
publicstringreReplaceNoCaseWithCallback
requiredstringvalue
requiredstringregex
requiredfunctioncallback
booleanreturnGroupsfalse
Transforms the provided string to a regular expression. Flags will be ignored.
publicstringreTransform
requiredstringvalue
publicbooleanstartsWith
requiredanystring
requiredanyvalue
publicbooleanstartsWithNoCase
requiredanystring
requiredanyvalue
Returns if the provided string contains any string in the provided array. Matching is case-insensitive.
publicbooleanstringContainsAny
requiredstringvalue
requiredarrayelements
Converts the provided string to a CSS class friendly format.
publicstringtoCssFriendly
requiredstring, string[]value
booleanmultiClasstrue
Converts the provided string to a file name friendly format.
publicstringtoFileFriendly
requiredstringvalue
stringspaceCharacter_
Converts the provided string to a folder name friendly format.
publicstringtoFolderFriendly
requiredstringvalue
stringspaceCharacter_
Converts the provided string to an URL friendly format, typically used for SEO.
publicstringtoSeoFriendly
requiredstringvalue
stringlanguage
structOPTIONS{}
optionarraypreserveCharacters[]
Replaces all conflict-laden characters.
publicstringtoSqlFriendly
requiredstringvalue
publicstringtoNameCase
requiredstringvalue
required"COMPANY", "PERSON"type
Converts the first letter of each word to uppercase and the remaining letters to lowercase.
publicstringtoTitleCase
requiredstringvalue
structOPTIONS{}
optionnumericlower0
optionnumericupper0
Removes all empty lines within the provided string.
publicstringtrimEmptyLines
requiredanyvalue
Removes leading, trailing, consecutive and protected whitespaces.
publicstringtrimExtended
String to remove whitespaces in.
requiredstringvalue
Removes all tabs and obsolete newlines within the provided string.
publicstringtrimIndentation
requiredanyvalue
publicstringtrimLeadingZeros
requiredstringvalue
Compares each character of the provided strings and returns the remaining part of the first string that is not equal to the second string.
publicstringtrimToDifference
requiredstringvalueA
requiredstringvalueB
stringellipsis