谷歌API错误,但仍然有效

red*_*ess 32 javascript google-api google-drive-api google-picker

我在连接到google drive API时在我的localhost上收到此控制台错误,但我在脚本中配置的选择器成功显示了我的驱动器内容:

无法在'DOMWindow'上执行'postMessage':提供的目标来源(' https://docs.google.com ')与收件人窗口的来源(' http:// localhost:8000 ')不匹配.

加载" https://docs.google.com/picker?protocol=gadgets&origin=http%3A%2F%2Flocalho ... 2photos%22))&rpctoken = yxxydsx40r21&rpcService = 2dngvfb4tj9x&thirdParty = true" 时遇到无效的"X-Frame-Options"标题:'ALLOW-FROM http:// localhost:8000 '不是公认的指令.标题将被忽略.

我是否会忽略这一点,还是会给我带来麻烦?

Nej*_*ani -1

你必须控制Google的HTTP标头,确保使用有效的选项 X-Frame-Options