Glad to hear that you got the new loader and library to work. However, it sounds like you are using AppsScript to use Google Charts. This has a different way of loading the library and interfacing with it. (Spreadsheets also have their own implementation of charts that look like Google Charts, but are not.) I don't know what your downloads are about, but you'll have to ask in a forum closer to the AppsScript community. Sorry I can't be of more help.
On Thu, Jun 25, 2020 at 4:05 PM Alina <[email protected]> wrote: > Thank you so much for your response Daniel, it was simple we just change > the new libraries and all it works. > > I take advantage of the thread of this message to ask you about an error > that we are having lately with google drive downloads in web applications. > I do not know where can i post it, because it is quite maddening because > of i can not find any solution for this, and maybe this issue sounds to you. > > We are working with multiple google spredsheets in app script > applicactions, downloading and export file and until three weeks ago it > seems to work perfectly, but not it give us an empty tab when we click de > button download. > > The code is so simple: > > var URL = " > https://drive.google.com/uc?export=download&confirm=no_antivirus&id="; > window.open(URL, "_blank"); > > Initially it does not do anything, but when you refresh the page twice, it > download perfeclty. So, we do not understand where could be the problem, > and why the first time it not works, and only in the refresh do. > > We have read that this is a generalized sandbox issue, because of the > allow downloads attribute does not exist anymore. > > We have tried in different way, llike: > > <iframe sandbox="allow-same-origin allow-scripts allow-popups allow-forms > allow-downloads-without-user-activation " src="hhttps:// > drive.google.com/uc?export=download&confirm=no_antivirus&id=" > style="border: 0; width:130px; height:20px;"></iframe> > > Maybe could be related to our web server > configuration, with Content-Security-Policy like i saw in some posts, but > i`m not sure about that. > Can we set up this configuration in some way, in Google Web App script? > This is related to entire domain, or maybe just our Google script site > particullary? > > Do you know something about that? Are there some groups of this kind of > issue or topic? > > Thank you so much, i will appreciate your help! > > El jueves, 21 de mayo de 2020 a las 18:27:39 UTC+2, Daniel LaLiberte > escribió: > >> If you are using the 'autoload' parameter, then the problem is very >> likely that you must now use strict JSON for the value of that parameter. >> This used to work, but it was insecure, so now we process the parameter >> with JSON.parse. >> >> It might be easier for you to just replace the use of the autoload >> parameter with a couple lines of code that do the equivalent, using >> google.charts.load and google.charts.setOnLoadCallback. >> >> If you are getting an error about google.visualization being undefined, >> then the loader did not finish loading the library before you started >> depending on it. That's what the setOnLoadCallback is for. >> >> >> On Wednesday, May 20, 2020 at 7:14:23 PM UTC-4, Dianna Whitt wrote: >>> >>> We are having the same problem. Charts were failing intermittently but >>>> frequently you could refresh and they would display. But as of yesterday, >>>> we are no longer able to display them. >>> >>> >>> On Chrome the error is: Uncaught TypeError: Cannot read property >>> 'ChartWrapper' of undefined >>> On Firefox the error is: Typeerror: google.visualization is undefined. >>> >>> The line failing is the call to google.visualization.ChartWrapper. I >>> have verified that the data being passed is valid JSON data. >>> >>> I tried to change from jsapi to www.gstatic.com/charts/loader.js but it >>> makes no difference. >>> >>> Any assistance would be appreciated, >>> Dianna >>> >>> >> -- > You received this message because you are subscribed to the Google Groups > "Google Visualization API" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/google-visualization-api/4a856f1a-1a0e-45fa-9333-d88ef5b60796n%40googlegroups.com > <https://groups.google.com/d/msgid/google-visualization-api/4a856f1a-1a0e-45fa-9333-d88ef5b60796n%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Daniel LaLiberte <https://plus.google.com/100631381223468223275?prsrc=2> [email protected] <[email protected]> Cambridge MA -- You received this message because you are subscribed to the Google Groups "Google Visualization API" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/google-visualization-api/CAOtcSJNmeQ0RkM1rtTg0E9Qw52ALvJUPfRdfwc3ezdanywZrZw%40mail.gmail.com.
