layer.js关闭子窗口及刷新父窗口】的更多相关文章

一.JS实现关闭当前子窗口,刷新父窗口 JS代码如下: <script> function refreshParent() {  window.opener.location.href = window.opener.location.href;  window.close();   }              </script>…
一.js实现关闭当前子窗口,刷新父窗口 JS代码如下: <script> function refreshParent() {  window.opener.location.href = window.opener.location.href;  window.close();   }              </script> html页面代码如下: <input type="button" id="btn1" class=&qu…
有时我们需要在新打开的窗口里面编辑信息,等编辑完了,需要将当前窗口关闭并且刷新父窗口,以使修改生效,本文就是介绍用 javascript 来实现"更新记录后关闭子窗口并刷新父窗口". 父窗口代码: <a href="javascript:void(0)" onclick="window.open('child.html','child','width=400,height=300,left=200,top=200');">打开子窗口&…
本文实例讲述了layer实现关闭弹出层刷新父界面功能.分享给大家供大家参考,具体如下: layer是一款近年来备受青睐的web弹层组件,她具备全方位的解决方案,致力于服务各水平段的开发人员,您的页面会轻松地拥有丰富友好的操作体验. 方案一: 在layer弹出层中调用父界面重新加载函数 window.parent.location.reload(); var index = parent.layer.getFrameIndex(window.name); parent.layer.close(in…
在需要layer.js弹窗口时,当编辑完窗口内容,需要关闭及刷新父窗口时: $("#senddata").click(function(){var id = $('input[name=id]').val();var amount = $('input[name=amount]').val();var star = $('input[name=star]').val();$.post("{:url('admin/card/editPart_Data')}",{id:…
不知道大家有没有碰到类似的问题,当时的你是什么思路来处理这个问题呢?是url,session,cookie,还是…… 今天笔者就遇到了这个问题,当时的想法如:url,session,cookie都尝试过,但是总是不能达到自己理想的目的 最后,在查看网页js资料的时候,看到了用Form.控件id.Click()方法为查询添加遮罩时,有感而发,我们这关闭子页面后,在父页面刷新自己,也可以同样的方法,仅记录…
var childWin = window.open("your URL"); //获取子窗口句柄childWin.onunload = function(){ //onunload是窗口关闭事件 this.opener.location.reload(); //childWin.opener为父窗口,及时刷新} 楼主也可以这样:(直接在子窗口中) window.onunload = function(){ this.opener.location.reload(); }更为简洁...…
iframe中刷新父页面方法及一些按钮刷新代码集合[原创+转]2009-07-23 11:12a页面里iframe了个b页面,我想实现在b页面里一个按钮,一按就刷新a页面,也就是父页面,不是只刷新iframe里面的b页面 哦~ 请问b页面里的<input type="button" class="btn" value=" 返 回 " onclick="history.back();">那个onclick 要怎么写呢…
父页面js:function btnAdd_onclick() {window.open("xxx.jsp", "","height=600, width=650, top=100, left=200,z-look=yes,toolbar=yes, menubar=no, scrollbars=yes, resizable=yes ,alwaysRaised=yes,location=no, status=yes" );} function re…
父页面 : html连接:<a href="javascript:void(0)" onclick="window.open(子页面URL)">js调用的方法: function closeWindow(object, isReload) { object.close(); isReload===true && window.location.reload();}子页面: $('#id').on('click',function(){ /…