搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

Learn More

requestStorageAccess() API

  • 無回覆
  • 0 有這個問題
  • 7 次檢視
more options

Hi,

I'm working on a website which uses third-party cookies for user login. But, recently, firefox has made Total Cookie Protection default making third-party cookies obsolete. To gain access to unpartitioned cookie jar, the documentation (https://developer.mozilla.org/en-US/docs/Web/API/Document/requestStorageAccess) tells that we have to call requestStorageAccess() API on a "user generated event". With this as a limitation, I have to add an additional button to create an user generated event. This is affecting my website's user experience.

Is there a way / hack to call this API without an user generated event like a button click.

Thanks in advance

Hi, I'm working on a website which uses third-party cookies for user login. But, recently, firefox has made Total Cookie Protection default making third-party cookies obsolete. To gain access to unpartitioned cookie jar, the documentation (https://developer.mozilla.org/en-US/docs/Web/API/Document/requestStorageAccess) tells that we have to call requestStorageAccess() API on a "user generated event". With this as a limitation, I have to add an additional button to create an user generated event. This is affecting my website's user experience. Is there a way / hack to call this API without an user generated event like a button click. Thanks in advance