You might see that the Dropbox Community team have been busy working on some major updates to the Community itself! So, here is some info on what’s changed, what’s staying the same and what you can expect from the Dropbox Community overall.

Forum Discussion

moosterbaan's avatar
moosterbaan
Helpful | Level 6
5 years ago

Embedder error on iPhone browsers

I am using the dropbox embedder on my website. It works as expected except on iPhone devices. I have tried it on two different iPhones using the Safari, Chrome, and Firefox apps and they all have the same result:

When the page loads, there is a message shown asking the user to allow cookies. Tapping the Allow Cookies button seems to reload the embedder, but the message is always shown. I have tried checking the settings of the browser apps, but there is no setting to turn cookies on or off. I also tried deleting cached files and cookies in the browser. This was at one point working on iPhones, but I was just told that it stopped about 1 month ago.

Below is the message that is logged in the console:

 

www.dropbox.com/log/telemetry:1 POST https://www.dropbox.com/log/telemetry 403
Unrecognized Content-Security-Policy directive 'worker-src'.

add_events:1 POST https://www.dropbox.com/2/event_logging/add_events?t=nkgw44qiKE1BDJTFf2rFy53gUP6WMLFqsUeGPH8-oJM 401
add_events:1 POST https://www.dropbox.com/2/event_logging/add_events?t=nkgw44qiKE1BDJTFf2rFy53gUP6WMLFqsUeGPH8-oJM 401
www.dropbox.com/2/client_metrics/record:1 POST https://www.dropbox.com/2/client_metrics/record 401
www.dropbox.com/2/users/get_current_account:1 POST https://www.dropbox.com/2/users/get_current_account 401
www.dropbox.com/2/previews/get_preview_data_batch:1 POST https://www.dropbox.com/2/previews/get_preview_data_batch 401
www.dropbox.com/dropins/log_event:1 POST https://www.dropbox.com/dropins/log_event 403
www.dropbox.com/dropins/log_event:1 POST https://www.dropbox.com/dropins/log_event 403
www.dropbox.com/2/previews/get_preview_data_batch:1 POST https://www.dropbox.com/2/previews/get_preview_data_batch 401
www.dropbox.com/log/telemetry:1 POST https://www.dropbox.com/log/telemetry 403

 

  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Staff rankDropbox Staff

    Thanks for the report. For reference, can you let me know:

    • Do you have the "Prevent Cross-Site Tracking" setting in Settings.app > Safari enabled?
    • Are you placing the Embedder inside an iframe?
    • moosterbaan's avatar
      moosterbaan
      Helpful | Level 6
      • Prevent Cross-Site Tracking was enabled by default. I tried disabling it, clearing the data, and closing safari then trying it again. The result was the same.
      • No, I am not using an iframe. Below is my relevant code:
        <html>
        <head runat="server">
        <script type="text/javascript" src="https://www.dropbox.com/static/api/2/dropins.js" id="dropboxjs" data-app-key="myKey"></script> </head> <body> <form runat="server"> <div class="row-container"> <a id="theFrame" class="row" style="height: 100%"></a> </div> </form> </body> </html> <script type="text/javascript"> let urlParams = new URLSearchParams(window.location.search); if (urlParams.has('Link')) { let element = document.getElementById('theFrame'); Dropbox.embed({ link: link }, element); } </script>

About Dropbox API Support & Feedback

Node avatar for Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

5,915 PostsLatest Activity: 2 days ago
333 Following

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X or Facebook.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!