Skip to content
Extraits de code Groupes Projets
Valider 7cc3bfc4 rédigé par diosmosis's avatar diosmosis
Parcourir les fichiers

Fixes #3135, fix opt-out form on Safari browsers by opening new window that sets the cookie.

This PR allows us to set 3rd party cookies in the opt-out form for Piwik. It works by opening a new window on form submission, reloading the new window, and setting the cookie on this reload. It is necessary to reload the window, because the session cookie isn't set, so the nonce won't be detected & so, the ignore cookie won't be set.

It works whether JavaScript is enabled or not, and other browsers still get the better UX.

The new window is closed immediately after opening, if JS is enabled.

There is also a new UI test for the opt out form, plus a small change to the UI testing framework to allow switching the user agent during tests.
parent dffd7bc7
Chargement en cours
Chargement en cours
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter