Privacy Settings Code doesn't work in Wix website

I’ve copied the code from ‘Privacy Settings On Your Page’ into an embedded HTML element on my WIX website editor and although the body of text shows up the link isn’t live and doesn’t reopen the settings.

I’ve tried looking at the help pages but I’m not an expert in coding. :roll_eyes:

I’m reaching out in the hope that someone can please tell me what I should do? I think it is a wix problem because I’ve had this issue with other things when it comes to embedding code in an html snippet.

My website is

Many thanks, kindest regards, Simon


I don’t see Piwik PRO installed on the linked page.

Hello Kuba, my apologies. I’ve got the Piwik Pro installation code in my header now. I’d paused it as I’d been having problems with the html code injection on my cookie policy page with the Piwik Pro ‘privacy settings’ code. I’d really appreciate you having a look. I’ve since read that Wix uses iframes to inject the code snippets onto pages and I wonder if that is the reason that the ‘privacy settings’ button isn’t a live link. I’d be perfectly happy to have a link on the footer of my pages if that was an option.

Out of interest, CookieYes cookie platform wrote to me with an answer regarding adding their links to my site as I was having a similar problem and they suggested this (link below) which worked, its just that I don’t know how to use this code and Piwik’s code together in order to achieve a workable result. Kindest regards, Simon

Just trigger'openConsentForm', console.log, console.error); after clicking on the link. :slight_smile:

Hello Kuba, thank you for replying so quickly. Much appreciated. Please forgive me, could you tell me where I put the line of code you gave me? So for example, if I have a ‘cookie settings’ link at the bottom of my footer, how could I implement the line of code you gave me. Is it a case of adding a line of text then going into the Developer Mode Velo of my Wix website and adding your line of code? I’m sorry. Kindest regards,

Based on the screenshot it looks good. Not sure if it’s a button or link in you case. Just target the right button/link and add the mentioned code inside this function.

Hi Kuba, thank you. I’ve added the line of code you’ve given me, please see red arrows on screenshot. Do you think this looks ok? It’s an ordinary text box with hopefully your code which will fire upon a click. I’ve not published the changes yet in case I’ve got it wrong. Thank you for your patience. :smiley:

Looks good. Maybe there’s some option to preview it instead of publishing?

Hi Kuba, unfortunately the line of code didn’t work. Nothing happens when you click upon the text. I’ve attached some screenshots of possibly another way of doing it? I don’t know if it will work? I was testing out CookieYes consent manager last week and they suggested I enter this code into the custom code body of the wix website, using the ‘comp id’ where the text link appears in the footer of the website. I’m afraid I don’t have the knowledge to transpose their code with yours, do you have any ideas?

By the way, this is the link to my test page for cookie policy with Piwik Pro’s iframe showing the button not working.

I don’t suppose there’s a way of having Piwik’s own floating sticky ‘cookie icon’ in the bottom left of the screen that people can click on? Could it be part of Piwik’s dashboard and something that is part of the main code installation in the header of websites? CookieYes do this but I’d rather use Piwik’s consent manager.

Many thanks, Kindest regards, Simon

I tested it using the console and it worked, so it’s all about understanding how Wix handles custom JavaScript. Did you see any errors in the console after implementing it? Right now I can see that Piwik PRO is not installed so I can’t really help.