-
- Téléchargements
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
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Affichage de
- plugins/CoreAdminHome/Controller.php 26 ajouts, 9 suppressionsplugins/CoreAdminHome/Controller.php
- plugins/CoreAdminHome/lang/en.json 2 ajouts, 1 suppressionplugins/CoreAdminHome/lang/en.json
- plugins/CoreAdminHome/templates/optOut.twig 39 ajouts, 3 suppressionsplugins/CoreAdminHome/templates/optOut.twig
- tests/UI/specs/OptOutForm_spec.js 59 ajouts, 0 suppressiontests/UI/specs/OptOutForm_spec.js
- tests/lib/screenshot-testing/support/page-renderer.js 5 ajouts, 0 suppressiontests/lib/screenshot-testing/support/page-renderer.js
- tests/resources/overlay-test-site/index.html 3 ajouts, 0 suppressiontests/resources/overlay-test-site/index.html
tests/UI/specs/OptOutForm_spec.js
0 → 100644
Veuillez vous inscrire ou vous se connecter pour commenter