有个https站点https://www.example.com,其中包含一个指向同一站点中另一个PHP页面target.php的iframe。
<iframe src="/target.php"></iframe>
使用以下方法将请求重定向到另一个http url:
header("Location: http://demosite/page" ,TRUE, 307)
不幸的是,这个重定向到http站点并不是从https iframe起作用的,虽然它是从http页面的iframe开始工作的。
我在target.php中尝试了file_get_contents(http:// demosite / page),却没有以正确的格式返回页面。
有人能告诉我如何在https页面的iframe中显示http页面吗?
提前谢谢你!