Asynchronous ad slots can be "remotely controlled" via various JavaScript variables, so the ad slot code itself does not need to be modified. For this purpose, a script block (<script> ... </script>) is created before the ad slot, where these variables are defined. The ad slot code will then collect these variables and adjust its behavior accordingly.
The following variables are available:
Variable | Values | Description |
window.asm_gdpr | 0/1 |
0 = GDPR should not be used, do not request TCF status 1 = GDPR should be used, TCF status will be requested (default) |
window.asm_gdpr_consent | String | TCF consent string (normally retrieved automatically); asm_gdpr_feedback must be true |
window.asm_gdpr_feedback | true / false | Indicates that the TCF consent string is already available and does not need to be retrieved again (see asm_gdpr_consent) |
window.asm_global_params | String |
URL-encoded list of parameters to be passed to all ad slots on
the page.
Example: "&abc=123&def=456&ghj=sch%C3%B6n" ("schön" URL-encoded: sch%C3%B6n) |