<iframe src='https://docs.google.com/viewer?url=https://docs.google.com/document/d/125CJmmlBfy7UgfYuBAmb1_HSCuyz8NV133361KTK1SE/export?format%3Dpdf&id=125CJmmlBfy7UgfYuBAmb1_HSCuyz8NV133361KTK1SE&embedded=false' frameborder='0'></iframe>
after this code I have next error
在这段代码之后,我有下一个错误
Refused to display 'https://docs.google.com/a/myrussiaonline.ru/viewer?url=https://docs.google.…ormat%3Dpdf&id=125CJmmlBfy7UgfYuBAmb1_HSCuyz8NV133361KTK1SE&embedded=false' in a frame because it set 'X-Frame-Options' to 'SAMEORIGIN'.
If I set
如果我设置
<iframe src='https://docs.google.com/viewer?url=https://docs.google.com/document/d/125CJmmlBfy7UgfYuBAmb1_HSCuyz8NV133361KTK1SE/export?format%3Dpdf&id=125CJmmlBfy7UgfYuBAmb1_HSCuyz8NV133361KTK1SE&embedded=true' frameborder='0'></iframe>
Then, all fine
然后,所有罚款
Can I set &embedded=false
and have correct render without error?
我可以设置和嵌入=false吗?
Thanks
谢谢
4 个解决方案
#1
2
The only way I've found to get the Google Docs Viewer to work in an iframe is:
我发现让谷歌文档查看器在iframe中工作的唯一方法是:
<iframe src="https://docs.google.com/viewer?srcid=[YOUR_FILE'S_ID_HERE]&pid=explorer&efh=false&a=v&chrome=false&embedded=true" width="800" height="600" style="border: none;"></iframe>
#2
1
First you should go to your document on google drive :
首先,您应该查看谷歌驱动器上的文档:
- click file
- 点击文件
- publish to the web
- 发布到网上
- embed
- 嵌入
- publish
- 发布
You will get the code of the iframe you can use it to visualize your spreadsheet without the possibility to edit it
您将得到iframe的代码,您可以使用它来可视化电子表格,而不需要编辑它
#3
1
Try this tutorial-
尝试本教程- - - - - -
https://www.youtube.com/embed/A5SkbcId-v0
https://www.youtube.com/embed/A5SkbcId-v0
U should have your answer.
你应该有你的答案。
Update-
According to Google Policy, if u like to have your document viewed with a iFrame, then embedded=true
should be in the URL.
根据谷歌策略,如果您希望使用iFrame查看您的文档,则在URL中嵌入=true。
Demo Code-
演示代码,
<iframe src='https://docs.google.com/viewer?url=https://docs.google.com/document/d/125CJmmlBfy7UgfYuBAmb1_HSCuyz8NV133361KTK1SE/export?format%3Dpdf&id=125CJmmlBfy7UgfYuBAmb1_HSCuyz8NV133361KTK1SE&embedded=true' frameborder='0'></iframe>
#4
0
No, you can not, this parameter is specify that source would be embedded. And the idea behind using it is to avoid clickjacking attacks
不,您不能,这个参数指定源将被嵌入。使用它的想法是避免点击攻击。
#1
2
The only way I've found to get the Google Docs Viewer to work in an iframe is:
我发现让谷歌文档查看器在iframe中工作的唯一方法是:
<iframe src="https://docs.google.com/viewer?srcid=[YOUR_FILE'S_ID_HERE]&pid=explorer&efh=false&a=v&chrome=false&embedded=true" width="800" height="600" style="border: none;"></iframe>
#2
1
First you should go to your document on google drive :
首先,您应该查看谷歌驱动器上的文档:
- click file
- 点击文件
- publish to the web
- 发布到网上
- embed
- 嵌入
- publish
- 发布
You will get the code of the iframe you can use it to visualize your spreadsheet without the possibility to edit it
您将得到iframe的代码,您可以使用它来可视化电子表格,而不需要编辑它
#3
1
Try this tutorial-
尝试本教程- - - - - -
https://www.youtube.com/embed/A5SkbcId-v0
https://www.youtube.com/embed/A5SkbcId-v0
U should have your answer.
你应该有你的答案。
Update-
According to Google Policy, if u like to have your document viewed with a iFrame, then embedded=true
should be in the URL.
根据谷歌策略,如果您希望使用iFrame查看您的文档,则在URL中嵌入=true。
Demo Code-
演示代码,
<iframe src='https://docs.google.com/viewer?url=https://docs.google.com/document/d/125CJmmlBfy7UgfYuBAmb1_HSCuyz8NV133361KTK1SE/export?format%3Dpdf&id=125CJmmlBfy7UgfYuBAmb1_HSCuyz8NV133361KTK1SE&embedded=true' frameborder='0'></iframe>
#4
0
No, you can not, this parameter is specify that source would be embedded. And the idea behind using it is to avoid clickjacking attacks
不,您不能,这个参数指定源将被嵌入。使用它的想法是避免点击攻击。