Atm, there is no way to control (at least I don’t know how) when the Classic PP Consent Manager fires its Impression Event. If you are still waiting for some data to be available on the page to write it into a Custom Dimension BEFORE the Consent Impression (so the Impression can be analyzed together with that Custom Dimension value), you just can’t.
I wonder if this is possible with CookieInformation. It would solve a major race condition issue a client is having with the old Consent Manager. The ideal solution would be to fire the Consent Manager based on a Custom Trigger in Tag Manager.
Hi!
The Cookie Information tag template handles the consent form impression event using this piece of code:
window.addEventListener('CookieInformationFormShown', function () {
ppms.cm.api('trackMainFormView', function () {})
})
If you’re using the template there isn’t a way to turn this off in the UI, but you can copy the whole code from the template and add it as a custom code tag (just without this snippet). That way you can send the impression event whenever you want.
It’s a bit more tedious than just using the template, but you have more control over the events. If you want to inspect the template code, you can do it in the debug mode 
1 Like
Thanks a lot. Sounds like quite a hack. Will this have any impact on the built-in Consent Integrations (e.g “fire certain tags only if Consent to X exists”).
I also see that the Cookie Information Tag itself can have Triggers. Can’t those be used (e.g. if I fire a custom Data Layer Event page_data_ready when I know we have all we need, I use this Event to fire the CookieInformation Tag (and thus, the Consent Impression Event)?
- As long as the mapping is in place, it won’t have any impact on the built-in consent integrations
- That is also a valid option, but it can cause missing data if the information you need to fire the tag takes too long to load. For example, someone interacting with the banner before you send “page_data_ready” won’t be tracked properly. If it’s a matter of, let’s say, a second or two, then it’s probably safe to implement this.
I suggested the custom code option because it ensures that everything besides consent impression still fires on every page view. You get full control of the impression event and at the same time you ensure that the mapping is in place at the right time.
Ok thanks a lot, Sara, I will see what I can do with this.