js frameset iframe 页面跳转
2013-01-18 15:16
337 查看
关于js中"window.location.href"、"location.href"、"parent.location.href"、"top.location.href"的用法
"window.location.href"、"location.href"是本页面跳转"parent.location.href"是上一层页面跳转
"top.location.href"是最外层的页面跳转
举例说明:
如果A,B,C,D都是jsp,D是C的iframe,C是B的iframe,B是A的iframe,如果D中js这样写
"window.location.href"、"location.href":D页面跳转
"parent.location.href":C页面跳转
"top.location.href":A页面跳转
如果D页面中有form的话,
<form>: form提交后D页面跳转
<form target="_blank">: form提交后弹出新页面
<form target="_parent">: form提交后C页面跳转
<form target="_top"> : form提交后A页面跳转
关于页面刷新,D 页面中这样写:
"parent.location.reload();": C页面刷新 (当然,也可以使用子窗口的 opener 对象来获得父窗口的对象:window.opener.document.location.reload(); )
"top.location.reload();": A页面刷新
相关文章推荐
- js中常用framesetiframe页面跳转传参方法实例大全
- js 中 常用 frameset iframe 页面跳转 传参数值 方法示例大全
- JS页面跳转和js对iframe进行页面跳转、刷新
- js页面跳转和js对iframe进行页面跳转、刷新
- JS页面跳转和js对iframe进行页面跳转、刷新
- JS实现父页面跳转、iframe实现整页面跳转
- JS实现父页面跳转、iframe实现整页面跳转
- frameset、iframe框架登录跳转, 处理session为空的登录页面问题
- asp.net 在iframe 中页面跳转问题 js
- j 4000 s页面跳转和js对iframe进行页面跳转、刷新
- JS页面跳转和js对iframe进行页面跳转、刷新
- JS页面跳转+JS在Iframe页面跳转、刷新
- js 指定iframe 跳转指定页面
- js跳转页面被iframe嵌套的问题
- js实现 frameset页面跳转
- IE (6-11)版本,在使用iframe的框架时,通过a标签javascript:; 和js跳转parent.location的时候 出现在新页面打开的情况
- js实现页面跳转的几种方式
- js五种页面跳转
- js页面跳转代码
- js页面跳转的问题(跳转到父页面、最外层页面、本页面)