Onsite campaigns Segmentation & Conditions

You are here:
Estimated reading time: 1 min

Onsite campaigns (interactions, polls, content) can be displayed to only some recipients, in a similar way to our advanced historical segmentation.

Because segmentation takes into consideration browser, device and other page attributes you have many conditions to use.

First set of conditions

Those conditions should all be true, at the same time, for the set to return true.

Make sure you don’t add conditions that exclude themselves: User device is desktop and user device is mobile (user can’t be on desktop and mobile on the same time).

You can use page variables or any of our conditions, all connected through AND operators, so all will need to be true at the same time.

or another example:

When there is no condition added to the first set, but conditions exist in the second set, the first will return true.

Second set of conditions

At least one condition from this set needs to be true, for the whole set to be true.

The operator between first set (A) and second set (B) can be AND and OR.

A (first set)B (second set)OperatorResult
truetrueANDtrue
truefalseANDfalse
falsetrueORtrue
falsefalseORfalse
How results from those conditions sets work combined.

Conditions List

Those conditions might always be updated with new ones, so it’s better to check them right under your Recipients tab in Interaction/Poll/Content campaigns.

Traffic sources

Ecommerce events & related

User profile & Behaviour

Technology

Operators

JS Expression Condition

For onsite campaigns you can use a new type of comparison in your conditions: JS expression

JS expression is a bit different than the rest but open you the door for unlimited validations. For example:

Examples

String expressions:

Integer/Float values expressions:

Expression usage:

  • JS expression you enter on the right must return true or false. Any other returned value will be considered false.
  • maximum length of expression is 50 characters.
  • the expression string you enter is evaluated using JS eval method.
  • (x) from the expression gets replaced with the real value of the condition:
    • if it’s null then it will be replaced with null
    • if it’s string make sure you put it into quotes
    • make sure you add those parentheses without spaces

Potential use cases:

  • display a campaign every 3 pages: (x)%3==0
  • length of utm term or search query is exactly 3 characters. “(x)”.length==3

Is Any Of (is not any of)

This operator works like a list, where the values needs to be separate by comma.

Example: test,test1,value

Was this article helpful?
Dislike 0
Views: 41