reEscape

Escapes regular expression control characters within a string.

reEscape(string); → returns string

Argument Reference

string string
Required

The string you that to escape.

Examples
Sample code invoking the reEscape function

reEscape('*.{}[]exam?ple')

Expected Result: \*\.\{\}\[\]exam\?ple

Signup for cfbreak to stay updated on the latest news from the ColdFusion / CFML community. One email, every friday.

Fork me on GitHub