Select to view content in your preferred language

Download Disallowed when WAB App embedded

1185
2
Jump to solution
12-20-2023 08:37 AM
Labels (1)
BlytheSpendlove
Regular Contributor

Good morning, we are in the process of upgrading to ArcGIS Enterprise 11.1 and as such, are trying to re-create Map Series applications with Experience Builder and/or Instant Apps.

Unfortunately, we have found that when we embed a link to a WAB app into the page, everything appears to work until you try and download anything within the application. When that happens, the download is blocked with the following message: "Download is disallowed. The frame initiating or instantiating the download is sandboxed, but the flag 'allow-downloads' is not set. See https://www.chromestatus.com/feature/5706745674465280 for more details."

This is causing a lot of problems for us, because there are quite a few widgets that are supposed to allow users to download something to their computer. Examples include (but are not limited to) exporting csv results from attribute table, and exporting drawings from the draw widget.

How can we get around this issue? I have tried this in both experience builder and instant apps, and within experience builder, I have tried it both by embedding a url directly, as well as embedding an iframe via the code option.

I have found a similar post about dashboards here that mentions using the classic version of dashboards instead, but that doesn't really help in my use case: Solved: Downloading CSV from Embedded Web App - Esri Community

Thank you,
Blythe Spendlove

@TonghuiMing @AlixVezina @Grant-S-Carroll @DanJiang @ShengdiZhang 


0 Kudos
1 Solution

Accepted Solutions
Grant-S-Carroll
Esri Contributor

Hi Blythe

The disallowing of downloads is a default setting now, as discussed in the link you posted, to prevent malicious use of software. We experienced something similar recently with a client where the default embed widget was disallowing popups to be displayed. Given we are working in a trusted environment, we got around this by creating a custom widget to support the use of the popups. I have modified this code now to set the allow-downloads in the iFrame attributes. Code is attached, as you are using Enterprise 11.1 you should be able to import this in to your Enterprise to be used within ExB. See the details here . 

I have included two versions of the widget, one compiled, ready to drop on to the web server and bring in to Enterprise, and the second is the source code of the uncompiled code, just so if you need to modify or change in the future you can, or if you want to scan for your own security purposes. Note, this is pretty much the out of the box widget, with the updated iFrame attributes.

I've not had a chance to test this, but hopefully it works out of the box.

Cheers

View solution in original post

2 Replies
Grant-S-Carroll
Esri Contributor

Hi Blythe

The disallowing of downloads is a default setting now, as discussed in the link you posted, to prevent malicious use of software. We experienced something similar recently with a client where the default embed widget was disallowing popups to be displayed. Given we are working in a trusted environment, we got around this by creating a custom widget to support the use of the popups. I have modified this code now to set the allow-downloads in the iFrame attributes. Code is attached, as you are using Enterprise 11.1 you should be able to import this in to your Enterprise to be used within ExB. See the details here . 

I have included two versions of the widget, one compiled, ready to drop on to the web server and bring in to Enterprise, and the second is the source code of the uncompiled code, just so if you need to modify or change in the future you can, or if you want to scan for your own security purposes. Note, this is pretty much the out of the box widget, with the updated iFrame attributes.

I've not had a chance to test this, but hopefully it works out of the box.

Cheers

BlytheSpendlove
Regular Contributor

Grant, thank you so very much, this is super helpful!

0 Kudos