contains( )


Refines a query to match items whose specified property value contains a specified string.

The contains() function refines an EventsQueryBuilder to only match items where the value of the specified property contains the specified string. Matching with contains() is case-sensitive, so "TEXT" does not contain "text".

You can only use contains() with a property whose value is a String.

Method Declaration
Copy
Method Parameters
propertyNamestringRequired

The property whose value will be compared with value.

Supported properties:

  • title
  • status
  • slug

valuestringRequired

The value to match against.

Returns
Return Type:EventsQueryBuilder
Was this helpful?
Yes
No