Using String Functions
String functions are used to manipulate text or numeric strings. They can be used to replace characters in a string, to compare the value of two strings, to find text within a string, and many other operations. ColdFusion offers more than 30 such functions; I'll detail only the most commonly used functions here.
Find() and FindNoCase()
Usage: Find(search_string, target_string)
These two functions search for text within a string. Find() performs a case-sensitive search for the specified text, whereas FindNoCase() ignores case. The first parameter specifies the text to look for, the second the string in which to search.
If the search doesn't find any matching text, both Find() and FindNoCase() return a 0. If they do find ...
Get Sams Teach Yourself ColdFusion® in 21 Days now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.