簡體   English   中英

MEAN.js未在iframe中顯示

[英]MEAN.js not showing in iframe

我必須在iframe中顯示MEAN.JS應用,因此我從一個簡單的html文件開始:

<iframe style="height: 100%; width: 100%;" src="http://localhost:3000/#!/workouts"></iframe>

但是iframe內容為空,請有人幫我嗎?

知道了:我的應用程序使用的是Helmet( https://github.com/evilpacket/helmet ),該頭盔在X-Frame-Options中設置了DENY。 因此,在我的Express配置中,我設置了:

app.use(helmet.xframe('ALLOW-FROM', 'www.mydomain.com'));

而且有效

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM