1.用iframe、弹出子页面刷新父页面iframe

<script language=JavaScript>
  parent.location.reload();
</script>

2.弹出子页面

<script language=JavaScript>
window.opener.location.reload();
</script>

3.子窗口刷新父窗口

<script language=JavaScript>
self.opener.location.reload();
</script>

4.刷新以open()方法打开的窗口

<script language=JavaScript>
window.opener.location.href=window.opener.location.href;
</script>

5.刷新以winodw.showModelDialog()方法打开的窗口

<script language="javascript">
window.parent.dialogArguments.document.execCommand('Refresh');
</script>

6.点击 layer 中刷新当前页

var iframes=  parent.document.getElementsByTagName('iframe');
for(var i=0;i<iframes.length;i++){
  var src=iframes[i].contentWindow.location.href;
  console.log( src);
  if(src.indexOf("table.jsp")!=-1){
    console.log( "刷新:"+src);
    parent.document.getElementsByTagName('iframe')[i].contentWindow.location.reload(true);
  }
}
 parent.document.getElementById('my_iframe').contentWindow.location.reload(true);

javascript刷新父页面的各种方法汇总的更多相关文章

  1. javascript刷新父页面方法总结

    用iframe.弹出子页面刷新父页面iframe <script language=JavaScript> parent.location.reload(); </script> ...

  2. javascript刷新父页面的内容

    适应于超级链接和弹出窗口 function RefreshParent() {     if (window.opener != null) {                             ...

  3. window.parent与window.opener、window.showModalDialog的区别 opener和showModalDialog刷新父页面的方法

    项目中使用案例: 父窗体 <s:form namespace="/forexagent" id="listSearchForm" name="t ...

  4. layui: 子iframe关闭/传值/刷新父页面

    https://www.cnblogs.com/jiqing9006/p/5135697.html layer iframe层的使用,传参   父层 <div class="col-x ...

  5. ThinkPHP 表单提交操作成功后执行JS操作如何刷新父页面或关闭当前页等操作

    ThinkPHP 表单提交操作成功后执行JS操作如何刷新父页面或关闭当前页等操作 .操作成功后刷新父页面 $this->assign('jumpUrl', "javascript:wi ...

  6. Ionic3关闭弹出页面,跳转到列表后刷新父页面

    记得上次写过一篇如何弹出页面的文章,好像是2月28号ionic3 Modal组件那一篇,这篇也算那一篇的续集吧!这篇是弹出的页面关闭后刷新父页面的干活!上代码! 弹出页面:(关闭的时候可以传入值,再父 ...

  7. iframe刷新父页面

    iframe页面是内嵌到父页面的,当点击iframe页面的服务器控件时,默认只刷新iframe页面,父页面是不会刷新的.若想刷新父页面,可以使用js来实现,如 1. parent.location.r ...

  8. jquery Jbox 插件实现弹出窗口在修改的数据之后,关闭弹出窗口刷新父页面的问题

    http://blog.csdn.net/nsdnresponsibility/article/details/51282797 问题如题: 这里我们在父页面定义一个全局的变量来标识是否需要刷新父页面 ...

  9. showModalDialog后如何刷新父页面

    最近一个项目使用到的.在网上查了好久,有的可行,有的就不行.总结一下吧.方案一:父页面:window.showModalDialog('User.jsf?USERCODE='001'&Rnd= ...

随机推荐

  1. We FALL ASleep At Night, We Do REST Right

    We Do Sleep At Night, We Do REST Right 前言 REST 起源 REST 约束 客户端 - 服务端 无状态 缓存 统一接口 分层系统 按需代码 统一接口约束 资源识 ...

  2. 微服务日志之Spring Boot Kafka实现日志收集

    前言 承接上文( 微服务日志之.NET Core使用NLog通过Kafka实现日志收集 https://www.cnblogs.com/maxzhang1985/p/9522017.html ).NE ...

  3. ASP.NET MVC下使用AngularJs语言(六):获取下拉列表的value和Text

    前面Insus.NET有在Angularjs实现DropDownList的下拉列表的功能.但是没有实现怎样获取下拉列表的value和text功能. 下面分别使用ng-click和ng-change来实 ...

  4. KMP string pattern matching

    The function used here is from the leetcode. Details can be found in leetcode problem: Implement str ...

  5. TI 开发板安装USB转串口驱动

    使用TI开发板的时候,USB转串口驱动没有,显示,无法识别设备.搜了好久才搜到相关驱动. 做个记录. 链接: https://pan.baidu.com/s/1ZT5zzVcU727jrYacKVoT ...

  6. ubuntu16.04 编译出错:fatal error: SDL/SDL.h: No such file or directory

    在ubuntu 16.04编译神经网络代码时候,遇到了这样一种错误? fatal error: SDL/SDL.h: No such file or directory 原因是SDL库没有安装,根据你 ...

  7. Maven - Tips

    1- Maven的Settings http://maven.apache.org/settings.html 2- Maven设置代理 示例: <proxies> <proxy&g ...

  8. centos7防火墙管理的变化

    当我们在centos7中输入service iptables status 查看系统的防火墙状态,会出现如下错误: 网上查阅才知道centos7的防火墙管理工具变了,原来的iptables已经不用了, ...

  9. LeetCode手记-Add Binary

    问题描述 问题分析 分析题意,此题实际是求解两个二进制数的和,但是有两点要注意: 1.字符串的长度不限,所以相应十进制数值很可能会超过int的上限. 2.二进制的加法规则是自右向左进位,需要注意,以题 ...

  10. 大数据项目相关技术栈(Hadoop周边技术)

    J2EE 框架Spring 开发框架 + SSH or SSM Lucene 索引和查询IKAnalyzer 分词Webmagic 爬虫 ETL工具:KettleSqoop 结构化数据库-hadoop ...