zoukankan
html css js c++ java
模态窗口弹出新页面解决办法
在模态窗口中,如有提交按钮,点击后会弹出新的页面。解决此问题有两种方法: 1、在head中,添加注意:不要在form中再添加target="_self" 否则失效 2、把弹出的窗口页面做成框架网页,去加载要展示的网 如果你的浏览器是IE5.5+,可以在对话框中使用带name属性的iframe,提交时可以制定target为该iframe的name。对于IE4+,你可以用高度为0的frame来作:例子, test6.htm =================== test7.htm =================== if(window.location.search) alert(window.location.search)
test8.htm ===================
3、另外一种解决方法 First and foremost, add the HTML tag () to the head sectionof your HTML document. Depending on your method of refreshing the form, adding this tag may be sufficient. Next check to see if your modal dialog now correctly refreshes itself.In some cases the modal dialog will still open a new window. For instance if you were using a JavaScript self.location.href= command then you will need to replace this with a simulated hyperlink click event. To do so, add a hyperlink to your page that is styled to be invisible (ie:
). Then replace your JavaScript self.document.location.href = ‘test.html’; with a click command to your hidden hyperlink as follows: document.getElementById('goLocation').href = 'test.html'; document.getElementById('goLocation').click();参考 :http://jwcooney.com/2011/12/22/showmodaldialog-opens-a-new-window-on-submit-or-location-href/ 参考 :http://blog.sina.com.cn/s/blog_4c6e822d0100r6jr.html
查看全文
相关阅读:
CCF计算机职业资格认证考试 201809-2 买菜
【CodeVS3013】单词背诵
【CodeVS3304】水果姐逛水果街Ⅰ
【CodeVS4246】奶牛的身高
【hdu1247】Hat’s Words
【CodeVS4189】字典
【CodeVS4244】平衡树练习
【poj3264】Balanced Lineup
【树状数组】
【CodeVS1163】访问艺术馆
原文地址:https://www.cnblogs.com/yongtaiyu/p/2804487.html
最新文章
Css——设置input输入框光标颜色
Css——显示2行数据,超出显示...
使用element-ui组件el-table时需要修改某一行或列的样式(包含解决选择器无效问题)
解决vue更新默认值时出现的闪屏问题
Vuex踩坑--数据刷新时丢失
cookie、sessionStorage和localStorage的区别
token和session的区别
(NOI2014)(bzoj3669)魔法森林
LCT动态树入门
NOIP2017列队(phalanx)解题报告
热门文章
NOIP2017逛公园(park)解题报告
浅谈平衡树splay
noip2017颓废记
开灯问题
DFS例题
jupyter 快捷键
Python——Numpy基础知识(一)
配置Jupyter
emmmmmm(官宣?)
洛谷 P1059 明明的随机数
Copyright © 2011-2022 走看看