Y
Y
Ysery2020-06-16 21:17:56
Accelerated Mobile Pages
Ysery, 2020-06-16 21:17:56

Cookie alert working in tandem on AMP and HTML pages?

Good day.

I rummaged through everything - search for plugins for WordPress, Google, but did not find anything working.

There is a site on WordPress, AMP pages are also implemented on it. Please tell me a solution (code, plugins) for displaying a block about the use of cookies on the site, which would work correctly and not force the user to agree twice to the use of cookies on the site.

Let me explain what I mean: using a Google search, a person is shown an AMP page, on which a plate about the use of cookies would be displayed to him. He agrees with this. And even if he goes from this page to some classic page (regular, non-AMP) of the site, he would no longer be asked this question.

I found only individual solutions, but in the end the request will be displayed here and there, and this annoys users.

Please tell me a solution that would work correctly with AMP and regular pages, in tandem, so to speak.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
Petr Volkhanov, 2020-07-21
@eprivalov

The simplest solution is to write a value to localstorage , and show it only to those who do not have your value.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question