http://xiangai.taobao.com
http://shop148612228.taobao.com

window.top.location.href 和 window.location.href 的区别

if (window.location.href == window.top.location.href) {     window.top.location.href = "/index.html"; }

top.window.location.reload 中top是什么意思 父框架的对象  比如 有网页  1.htm  <span id='str'>显示内容1</span> <iframe src='2.htm'></iframe>  2.htm  <input type='button' value='改变显示内容' onclick="top.document.getElementById('str').innerHTML='显示内容2222222';" />  也就是 如果 2.htm 里面 使用了: top.window.location.reload 那么就是 刷新父页面 1.htm 如果2.htm里面使用的是: window.location.reload 那就是 刷新框架 2.htm    父页面1.htm  不改变 参看资料:http://zhidao.baidu.com/question/334336921.html

posted @ 2012-02-17 17:01  万事俱备就差个程序员  阅读(2229)  评论(0编辑  收藏  举报

http://xiangai.taobao.com
http://shop148612228.taobao.com
如果您觉得对您有帮助.领个红包吧.谢谢.
支付宝红包
微信打赏 支付宝打赏