【发布时间】:2012-11-12 00:04:55
【问题描述】:
我在服务器(Heroku)上有这个 HTML 代码。在 www.example.com 的 iframe 中,我单击“登录到 google”按钮,但收到以下错误消息:
Refused to display document because display forbidden by X-Frame-Options
我尝试在 www.example.com 的标题上添加<meta http-equiv="X-Frame-Options" content="GOFORIT">,但仍然不起作用。有任何想法吗?谢谢
<html>
<head>
<title>Test</title>
</head>
<body>
<iframe src="http://www.example.com" width=1000 height=1000></iframe>
</body>
</html>
【问题讨论】:
-
可以看看这个线程stackoverflow.com/questions/6666423/…我测试过,它在我这边工作正常。
标签: html security iframe heroku x-frame-options