Hi Tim,
Visitor groups are evaluated each time they are used (e.g. to display a piece of content) which allows for circumstances where personalisation is done based on changing data (e.g. time of day). This means that, if you need to persist the result of a custom-written criterion like the one above, you'll need to add in a mechanism to persist that data such as setting a cookie or storing the result to a session. The change you mention in 11 relates to the inbuilt criteria which use the session to persist data but, in Epi 11, can use cookies if the session has been disabled.
Hi Tim
In your case you could probably change your criteria logic to:
As Paul mentions, the criteria will be evaluated on all requests to pages where this criteria is added (could for instance be because of a block personalization group or a security group rule). But in this way, even though the criteria will be evaluated many times, the decision will be made only once per browser session.
I want that visitors can see content only if the URL contains a specific key and value in url-parameters, for example `?clienttype=business`.
For that i have created following classes.
Setting class:
Criterion class:
It works. But now i want that it will be validated only once and then keeps it value the whole browser-session. Currently it seems that it checks the url-parameter on every request.
Even if i use the builtin "Visitor Group Membership" and add there a custom visitor group with the above criterion, it will always validate it on every request.
Is it a misunderstanding on my side how visitor groups work, or what is the correct way to implement this requirement?
We are still on EPI 10 but will switch to 11 soon. Is this change in EPI11 what i am looking for or is it already possible in 10?