AMP Integration
3 min
This is available only for the TCF V2 GDPR CMP.
The AMP integration of the PubConsent CMP is the one already shown in the instructions provided on the configurator.
We want to emphasize that it's important to correctly insert the configuration tags inside the tag. Like in the example:
...
<head>
<meta name="amp-consent-blocking" content="">
<script async custom-element="amp-consent" src="https://cdn.ampproject.org/v0/amp-consent-0.1.js"></script>
</head>
...If you use <meta name="amp-consent-blocking" content="..."> we ask you to reinsert the content of the attribute content .
Be careful if the shown configuration is already present to avoid duplicates.
Right after, in the tag, it's necessary to possibly insert the integration code at the top:
<amp-consent id="pubtech" layout="nodisplay" type="pubtech">
<script type="application/json">
{
"postPromptUI": "pubtech-post-prompt",
"exposesTcfApi": true,
"clientConfig": {"cmpUrl":"https://cmp.pubtech.ai/0/pubtech-cmp-v2.js"}
}
</script>
<div id="pubtech-post-prompt">
<button on="tap:pubtech.prompt(consent=pubtech)" role="button">Privacy settings</button>
</div>
</amp-consent>For further information on integration and script blocking in AMP, please refer to the official documentation of the AMP HTML project by clicking here.