contains

Summary

Checks if a string contains a specific element.

Usage

input|contains( sequence )

Parameters

NameTypeDescriptionRequired
sequence string The string that should be matched. Yes.

Returns

TRUE if there is a match, FALSE otherwise.

Description

This operator checks if the input string contains a specific sequence of characters. If a match is found, the operator will return TRUE, otherwise FALSE will be returned.

Examples

Example 1

{'Welcome to my homepage!'|contains( 'my' )}

Returns TRUE.

Example 2

{'Welcome to my homepage!'|contains( 'your' )}

Returns FALSE.

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2013 eZ Systems AS (except where otherwise noted). All rights reserved.