Javascript error | WordPress.org

Plugin Author
Phil

(@philsbury)

Hi @simkog,

I think what’s happening here is Age Gate is trying to do a focus trap (i.e preventing interaction with anything else until they confirm their age) but also cmp2ui looks like it also trying to do the same thing.

In Age Gate -> Advanced Settings, try disabling the “Trap focus” option and see if that fixes it. Clear the site cache after if you have one.

If it doesn’t, keep it active and let me know so I can have a quick look.

Thanks
Phil

Thread Starter
simkog

(@simkog)

Dear @philsbury,

That was a fast answer, thanks for that! But, your suggestion did not resolved the problem.

I keep the plugin active, if you want to test it yourself.

Best regards,
Gergo Simko

Plugin Author
Phil

(@philsbury)

Hi @simkog,

I don’t get the error so I think one part is fixed.

It seems your cookie message is what is trapping focus, but that appears behind Age Gate, so you can’t clear the age gate in order to accept the cookies.

I’m going to see if I can see a work around, but might be worth looking in the settings for the cookie notice to see if there’s either a way to include other elements (which is what I do in age gate), or to disable the focus trap there.

Like I say, going to see if there’s a way to show the cookies on top with some css of something.

Will report back soon!

Thanks
Phil

Thread Starter
simkog

(@simkog)

Dear @philsbury,

Yeah, it was some CSS conflict from our theme developer.

The problem was, that we had a custom blur effect on everything (except the age gate popup) when the age gate is shown and the cookie popup could not load properly.

Thanks for your suggestion! I am going to close this support question!

Plugin Author
Phil

(@philsbury)

Ah amazing! Happy it’s working now @simkog!

Thanks
Phil

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer