简体   繁体   English

为什么我无法在自己的页面中显示此页面?

[英]Why can't I display this page inside my own page?

This is the page I'm trying to display inside my own page : http://matchhistory.euw.leagueoflegends.com/en/#match-details/EUW1/2468687321 这是我要在我自己的页面中显示的页面: http : //matchhistory.euw.leagueoflegends.com/en/#match-details/EUW1/2468687321

I've tried different ways to achieve it, but they lead to a blank canvas. 我尝试了不同的方法来实现它,但是它们导致了一块空白的画布。


Method 1 (unsuccessful) : 方法1(不成功):

<div> 
<object type="text/html" data="http://matchhistory.euw.leagueoflegends.com/en/#match-details/EUW1/2468687321" width="800px" height="600px" style="overflow:auto;border:5px ridge blue">
</object></div>

Source : How to load an external webpage into a div of a html page 来源: 如何将外部网页加载到html页面的div中


Method 2 (unsuccessful) : 方法2(失败):

<div id="help"><iframe src="http://matchhistory.euw.leagueoflegends.com/en/#match-details/EUW1/2468687321" height="500px" width="600px"></iframe></div>

Source : Display the content of a div on another webpage in my website 来源: 在我网站的另一个网页上显示div的内容


I'm kind of a beginner in various languages, I may be missing some basics. 我是各种语言的初学者,我可能缺少一些基础知识。 Thanks for your help 谢谢你的帮助

That page has headers set that don't allow you to embed it. 该页面的标题设置不允许您嵌入它。

"Refused to display in a frame because it set 'X-Frame-Options' to 'SAMEORIGIN'." “拒绝显示在框架中,因为它将'X-Frame-Options'设置为'SAMEORIGIN'。”

I think you can get around this by using a HTTP requests. 我认为您可以通过使用HTTP请求来解决此问题。

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

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