【发布时间】:2014-04-30 00:56:49
【问题描述】:
我正在尝试在 iframe 中打开 http://teeSpring.com/。它抛出Refused to display 'http://teespring.com/' in a frame because it set 'X-Frame-Options' to 'SAMEORIGIN'. 错误。
我已经经历了多个答案,但没有一个对我有用。大多数解决方案都特定于 google-maps、facebook 或 youtube 视频。
这是我的代码:
<html>
<head>
<base target="_blank" />
<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script>
</head>
<body>
<iframe src="http://teespring.com" name="frame1" style="border: 0; width:20%; height:20%; overflow:auto;">
</iframe>
</body>
</html>
我确实使用了target="_blank",但没有运气。
注意:尝试打开第三方页面。所以我无法控制添加标题或其他元数据。
【问题讨论】:
-
您使用哪种服务器端语言?
-
暂时没有。现在我只有一个静态页面。
标签: html iframe x-frame-options