Houdini 21.0 Nodes APEX nodes

string::RegexReplace

Replaces instances of a regular expression with a replacement string.

On this page
Since 21.0

Returns True if at least one instance of the regular expression is replaced. Returns False if regex is not found in input, or regex is invalid. If the replacement is successful, the result is the modified string.

Inputs

regex: String

The regular expression.

input: String

The string to modify.

replace: String

The replacement string for the found regex instances.

numreplacements: Int

The maximum number of replacements. Defaults to 0, which means there is no limit to the number of replacements.

Outputs

success: Bool

Returns True if at least one occurrence of the regular expression is replaced.

replace: String

The string with the occurrences of regex replaced with replace.

See also

APEX nodes