These functions check whether a source contains a specific value. The result returned is either true or false (Boolean). Functions that produce a Boolean value are useful for building personalization rules and selections.

Function

Description

​fn:contains​

Determines whether a target string contains a specified substring.

​fn:containsIgnoreCase​

Determines whether a target string contains a specified substring, ignoring the case of the target string. It ignores whether the target string text is written in upper or lowercase.

fn:endsWith

Tests if a target string ends with the specified substring.

​fn:startsWith​

Tests if a target string starts with the specified substring.

​fn:indexOf​

Returns the index within a string of a specified substring.

​ecm:regexMatches​

Determines whether a specified value matches a given regular expression.

​ecm:regexMatchesIgnoreCase​

Determines whether a specified value matches a given regular expression. It ignores whether the target string text is written in upper or lowercase.

​ecx:isEmptyCouponList​

Determines whether coupon codes remain in the specified coupon list.