我想根据iframe导航在浏览器中更改URL,如下所示:
**[URL at navigator: http://localhost/]**
<html>
<body>
<iframe src="http://localhost/?loadiframe=true">
<!-- this is at the code retrieved by the iframe -->
<a id="mypage" href="http://localhost/mypage/?loadiframe=true">Navi</a>
</iframe>
</body>
</html>当用户单击#mypage链接时,浏览器中的URL将为:
http://localhost/mypage/iframe的src总是相同并不重要。
这是可能的吗?
也许使用ajax......??
发布于 2013-02-26 18:07:15
发布于 2013-02-26 18:17:41
如果将链接的target属性设置为_parent,则地址应在父窗口中打开:
<a id="mypage" href="http://localhost/mypage/?loadiframe=true" target="_parent">Navi</a>https://stackoverflow.com/questions/15086186
复制相似问题