繁体   English   中英

Google网站上的Apps脚本小工具开始引发CORS错误

[英]Apps Script Gadget on Google Site started throwing CORS errors

我有一个包含多个页面的Google站点,所有页面都包含一个Google Apps脚本小工具。 用户报告说,几个月前,Apps Script Gadgets停止工作。 我已经对其进行了测试,发现Apps Script小工具可以正确加载并显示UI服务中的内容,但是,单击任何运行功能的按钮时,Apps Script小工具会挂起,并且浏览器中的控制台错误显示:

Uncaught SecurityError: Failed to read the 'frame' property from 'Window': Blocked a frame                      
with origin "https://sites.google.com" from accessing a frame with origin
"https://xxxxxxxxxxxxxxxx-a-sites-opensocial.googleusercontent.com".
Protocols, domains, and ports must match.

Google是否更改了某种安全策略,以阻止向“应用脚本脚本”发出跨源请求? 有什么解决方法吗?

谢谢

斯图

我可以找到的唯一解决方案是用一个在新页面中打开Apps脚本URL的链接替换小工具。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM