Skip to content

Tamper: Find replace (multiline)

Plugin ID: eca_tamper_condition:find_replace_multiline

Available since: 1.0.0

Find and replace text, with multiple search/replacement patterns defined together.

Fields

Comparison operator — config key: operator

The available comparison operators like equals or less than.
When using the "Defined by token" option, make sure there is a token with this name: eca_tamper_condition:find_replace_multiline_operator

Type: select · Required: no · Default: equal

Allowed values: equal, beginswith, endswith, contains, greaterthan, lessthan, atmost, atleast, _eca_token, ''

Comparison type — config key: type

The type of the comparison.
When using the "Defined by token" option, make sure there is a token with this name: eca_tamper_condition:find_replace_multiline_type

Type: select · Required: no · Default: value

Allowed values: value, natural, numeric, lexical, count, _eca_token, ''

Case sensitive comparison — config key: case

Compare the values based on case sensitivity.

Type: checkbox · Required: no · Default: false

Negate the condition — config key: negate

Negates the condition. Makes TRUE to FALSE and vice versa.

Type: checkbox · Required: no · Default: false

Text to find and the replacements — config key: find_replace

Enter one match per line in the format search|replacement, though the separator can be changed below. The replacements will be processed in order provided above.

Type: textarea · Required: yes · Default: empty string

Search/replacement value separator — config key: separator

Control the character used to separate the "search" from the "replace" string in the field above. Defaults to "|", to match the value separator used on the Drupal core list fields.

Type: textfield · Required: yes · Default: |

Case sensitive — config key: case_sensitive

If checked, "book" will match "book" but not "Book" or "BOOK".

Type: checkbox · Required: no · Default: false

Respect word boundaries — config key: word_boundaries

If checked, "book" will match "book" but not "bookcase".

Type: checkbox · Required: no · Default: false

Match whole word/phrase — config key: whole

If checked, then the whole word or phrase will be matched, e.g. "book" will match "book" but not "the book". If this option is selected then "Respect word boundaries" above will be ignored.

Type: checkbox · Required: no · Default: false

Data to be tampered — config key: left

Type: textarea · Required: yes · Default: empty string

Data to compare with — config key: right

Type: textarea · Required: yes · Default: empty string