【发布时间】:2018-07-16 09:42:31
【问题描述】:
尝试使用 Google 趋势中的嵌入脚本会导致 Chrome 下出现以下错误。
Refused to display 'url' in a frame because it set 'X-Frame-Options' to 'sameorigin'.
我已将脚本放在 index.html 的正文中,并将其托管在本地以及外部服务器上。
据我所知,这是为了停止“点击劫持”,但 Google 提供的脚本不适用于他们自己的浏览器似乎很奇怪。 Firefox 运行良好。
这是 Google Trend 嵌入的根本问题,只是无法与 Google 自己的产品一起使用,还是我的服务器设置有问题?
【问题讨论】:
标签: javascript embed x-frame-options google-trends