support home

Back to website
Login  Sign up

re-open cookie-consent modal via js


as a frontend-developer, I want to re-open the cookie-policy with a link via javascript.

Currently I have create a link like <a href="#" class="iubenda-cs-preferences-link" >Cookies</a>. But this way, I suffer under the behavior, that only the first of such links does work. On our page, we use different footers (on different pages), where this link is included; and only the first does work; the 2nd one only works after a reload.

The class usage is like documented in the documentation (german version). 

I would like to have a JS-API-function like #showCP() or that a your class-name based solutions also works on links, loaded afterwards.

Feel welcome to forward this message or provide a different solution.

3 people like this idea
  • sorry for bouncing this topic; this is a serious request and we need a solution for it from you.

  • Oh, same problem i m facing.

  • I've installed the Iubenda Consent Solution JS SDK, and it appears to work. Once a user indicates their consent by scrolling or dismissing the notice, the banner goes away and, presumably, the consent is stored in the Iubenda system.        

    Once the consent is recorded, one must be able to retrieve it and Iubenda says this can be done using either the HTTP API or by JavaScript, however these methods are not well documented.

    How can I use JavaScript to retrieve the consent?


Login or Signup to post a comment