這個外掛並未在最新的 3 個 WordPress 主要版本上進行測試。開發者可能不再對這個外掛進行維護或提供技術支援,並可能會與更新版本的 WordPress 產生使用上的相容性問題。

WPO365 | SAMESITE

外掛說明

Plugin for WordPress websites that require a user to sign in (e.g. with Microsoft using the WPO365 plugin) and that are loaded inside an iframe (e.g. inside a Microsoft Teams App / Tab or similar). The plugin overrides the pluggable WordPress function wp_set_auth_cookie to always set SameSite=None to enable third-party usage of cookies.

Prerequisites

  • The SameSite=None flag is only respected by browsers such as Chrome when the cookie’s Secure flag is set. Therefore the website must use SSL for the plugin to effectively enable browser support for 3rd party cookies.

Support

I will go to great length trying to support you if the plugin doesn’t work as expected. Go to our Support Page to get in touch. I haven’t been able to test our plugin in all endless possible WordPress configurations and versions so I am keen to hear from you and happy to learn!

Feedback

I am keen to hear from you so share your feedback with me on Twitter and help me get better!

Open Source

When you’re a developer and interested in the code you should have a look at the corresponding gist at github.

安裝方式

Perform the following steps to install the plugin:

  • Go to WP Admin > Plugins > Add new and search for WPO365.
  • Click Install to install the plugin.
  • Click Activate to activate the plugin.

使用者評論

2020 年 9 月 2 日 1 則留言
This is a simple little solution that actually works. Easy set up, no hassle.
閱讀全部 2 則使用者評論

參與者及開發者

以下人員參與了開源軟體〈WPO365 | SAMESITE〉的開發相關工作。

參與者

將〈WPO365 | SAMESITE〉外掛本地化為台灣繁體中文版

對開發相關資訊感興趣?

任何人均可瀏覽程式碼、查看 SVN 存放庫,或透過 RSS 訂閱開發記錄

變更記錄

v1.3

  • Fix: Tested with latest versions of WordPress and PHP.

v1.2

  • Fix: Added support for PHP 8.

v1.1

  • Fix: The plugin would end up in an infinitely loop when using PHP 7.2 or older. This has been fixed by implementing a work-around that abuses the “path” or “domain” parameter of PHP’s “setcookie” function to sneak in the SameSite attribute because PHP does not escape semicolons.

v1.0

  • Initial version