Rich-text Reply

Visitor does not have cookie - NOT working properly. Help?

mkstvnsn 11-10-16
Accepted Solution

Visitor does not have cookie - NOT working properly. Help?

Below is my audience targeting. Two conditions. 1.) HAS optimizely test snippet. and 2.) DOES NOT HAVE cookie MOJO_AUTH.

 

This is not working. I DO have MOJO_AUTH and I am still triggering the experiment. What am I doing wrong?

 

Screen Shot 2016-11-10 at 11.11.47 AM.png

Level 2

CouchPsycho 11-10-16
 

Re: Visitor does not have cookie - NOT working properly. Help?

Hi,

try to set the condition for MOJO_AUTH to "equals" "true". Just a guess regarding expression evaluation.

Kind Regards

Michael



"the essence of the creative act is to see the familiar as strange." (anonymous)
mkstvnsn 11-10-16
 

Re: Visitor does not have cookie - NOT working properly. Help?

Thanks, Ill try, but the value is different for every user. This is the cookie that is applied to users who are logged in. The value is never "true" or "false".
Level 2
CouchPsycho 11-10-16
 

Re: Visitor does not have cookie - NOT working properly. Help?

Another option is custom javascript as an audience condition with this code:

 

typeof $.cookie('MOJO_AUTH') === 'undefined'

 

KInd regards

 

Michael 




"the essence of the creative act is to see the familiar as strange." (anonymous)
mkstvnsn 11-10-16
 

Re: Visitor does not have cookie - NOT working properly. Help?

Just tried and I have the same problem.
Level 2
mkstvnsn 11-10-16
 

Re: Visitor does not have cookie - NOT working properly. Help?

Tried the JS approach and now the experiment is not displayed regardless if the cookie is there or not.


Really confused as to why my first attempt did not work. The cookie is there. Optimizely just straight up ignores the rule I set.
Level 2
mkstvnsn 11-10-16
 

Re: Visitor does not have cookie - NOT working properly. Help?

It just came to my attention that the cookie is secure.. does that mean I will not be able to use it for targeting?
Level 2
CouchPsycho 11-10-16
 

Re: Visitor does not have cookie - NOT working properly. Help?

As far as i know, secure cookies (httpOnly) can not be read by javascript. Therefore JS-evaluation is not possible. I am quite sure, optimizely does not support this kind of cookies.



"the essence of the creative act is to see the familiar as strange." (anonymous)