Callbacks
Callback name | Description |
---|---|
MonsidoCookieOnLoad | Triggered when the cookie banner is initialized. |
MonsidoCookieOnShow | Triggered when the cookie banner is displayed. |
MonsidoCookieOnHide | Triggered when the cookie banner is hidden. |
MonsidoCookieOnAccept | Triggered first time the visitor makes a consent choice after page load. |
MonsidoCookieOnUpdate | Triggered when the visitor changes their consent decision. |
MonsidoCookieOnAccept | Triggered when the visitor accepts the use of cookies the first time after page load. |
MonsidoCookieOnUpdate | Triggered when the visitor changes the use of cookies. |
MonsidoCookieRunEssentialScripts | Triggered when the visitor gives consent to essential cookies. |
MonsidoCookieRunBasicScripts | Triggered when the visitor gives consent to basic cookies. |
MonsidoCookieRunMarketingScripts | Triggered when the visitor gives consent to marketing cookies. |
MonsidoCookieRunAnalyticsScripts | Triggered when the visitor gives consent to statistics cookies. |
MonsidoCookieRunPersonalisationScripts | Triggered when the visitor gives consent to preference cookies. |
Usage
window.MonsidoCookieOnLoad = function() {
console.log('Cookie Banner Loaded');
};
window.MonsidoCookieOnShow = function() {
console.log('Cookie Banner Shown');
};
window.MonsidoCookieOnHide = function() {
console.log('Cookie Banner Hidden');
};
window.MonsidoCookieOnAccept = function() {
console.log('Cookie Consent Accepted');
console.log('Consent', window.monsidoConsentManager.cookiesConsent);
};
window.MonsidoCookieOnUpdatet = function() {
console.log('Cookie Consent Changed');
console.log('Consent', window.monsidoConsentManager.cookiesConsent);
};
window.MonsidoCookieRunEssentialScripts = function() {
// Execute scripts that requires essential consent here
};
window.MonsidoCookieRunBasicScripts = function() => {
// Execute scripts that requires basic consent here
};
window.MonsidoCookieRunMarketingScripts = function() => {
// Execute scripts that requires marketing consent here
};
window.MonsidoCookieRunAnalyticsScripts = function() => {
// Execute scripts that requires statistics consent here
};
window.MonsidoCookieRunPersonalisationScripts = function() => {
// Execute scripts that requires preferences consent here
};