Reputation: 43
I need to insert the google remarketing code in my html site. problem is, with the GDPR coming, i must insert the code only after the user click on cookie notice. The google remarketing script does not support async load so the only viable solution is to use google tag manager (GTM). So, what i want to do is to tell GTM when to insert the google remarkening code. For that i need toset a custom trigger but i just can't make it work. in google tag manager i tried custom variable as primary cookie, global javascript var, etc. Can someone please show me how to do that? Thanks in advance!
Upvotes: 1
Views: 173
Reputation: 564
If your cookie notice has a class or id to key off, you can do something like this:
Upvotes: 0
Reputation: 14197
You need to push an event into the dataLayer when a user accepts the cookie policy, then in Tag Manager intercept that event with a trigger that activates your remarketing tag.
Upvotes: 1