Optimize
6.7K members online now
6.7K members online now
Discover how to select who is eligible to be in your experiment, and when they’re served experiment variations.
Guide Me
star_border
Reply

Targeting using the Data Layer

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

To Target an Experiment I'd like to use the Data Layer variables, however the variant is not firing when meeting the conditions.

 

I've read here that we need to be using Data Layer v2  which support nested variables.  Does anyone know how I do this or have any experience of this? 

 

Thanks,

 

 

 

 

Targeting using the Data Layer

Follower ✭ ☆ ☆
# 2
Follower ✭ ☆ ☆

Hi, Mike!

 

I have done a lot of these things. In what order are you code structured? To be able to target based on Data Layer variables I think you need have those defined before the GA/Optimize script is running (check https://support.google.com/360suite/optimize/answer/6262084?hl=en#tagging-best-practices under "Tagging Best Practices"). If you can share a link to the page I can have a quick look at it.

 

Best,

Simon