I have made the following changes, and it seems working now
- To include the header code script manually at the top of all pages
<script nowprocket>// Define dataLayer and the gtag function.window.dataLayer = window.dataLayer || [];function gtag(){dataLayer.push(arguments);}// Set default consent to 'denied' as a placeholder// Determine actual values based on your own requirementsgtag('consent', 'default', { 'ad_storage': 'denied', 'ad_user_data': 'denied', 'ad_personalization': 'denied', 'analytics_storage': 'denied'});</script>
2) At the GDPR Cookie Compliance Plugin (CCPA ready) admin plugin, included additional code on the “additional cookies” with gtag(‘consent’, ‘update‘ like for example:
<script nowprocket>
// Define dataLayer and the gtag function.
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
// After Accepting Additional Cookies
gtag('consent', 'update', {
'ad_storage': 'granted',
'ad_user_data': 'granted',
'ad_personalization': 'granted'
});
</script>
According to tag_assistant it seems working now.
Can you please confirm that such steps are required to have the “Consent” working with your Direct integration Plugin option (or did I miss something else)?
Thanks.
Hello,
That’s correct.
The above is what the ‘Direct Integration’ method does out of the box, however, if you found your own way to achieve that, that’s great.
More details on this topic is here:
https://support.mooveagency.com/topic/ga-gtm-consent-settings/
Hope this helps.