在弹出子窗口后,在不关闭子窗口前怎样控制不让父窗口关闭和打开新页,也就是不让父窗口有任何操作,谢谢! 嗯,建议使用模态对话框,或者在open出来的子窗口中加入如下代码window.onblur = function(){self.focus()} 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <script>window.showModalDialog("http://www.csdn.net","","dialogWidth:600px;dialogHeight:400px;center:1;scroll:0;help:0;status:0");</script> 用模式对话框,不过这只有IE支持,NS下就没办法了。window.showModalDialog("http://www.csdn.net","","dialogWidth:600px;dialogHeight:400px;center:1;scroll:0;help:0;status:0");在open出来的子窗口中加入如下代码window.onblur = function(){self.focus()}是有限的,比如在MyIE或者TE(腾讯的)中就不能达到效果了。而且,这样的话会有麻烦,当你都不想理会这几个窗口时。我倾向于使用 showModalDialog //用模式对话框,不过这只有IE支持,NS下就没办法了。在NS下。也会启用IE来弹出吧? 也就是模态和非模态的问题了,不过IE的编程可以用ShowModalDialog的 http://www.csdn.net/develop/Read_Article.asp?Id=15113http://expert.csdn.net/Expert/topic/2001/2001793.xml?temp=.1702082http://expert.csdn.net/Expert/topic/1911/1911975.xml?temp=.4667322关于模态窗口(showModalDialog)的专题讨论!1.模态窗口的打开2.模态窗口的关闭3.模态窗口的传递参数。4.其他。1.window.showModalDialog("DialogPage.aspx","newwin","dialogHeight: 200px; dialogWidth: 150px; dialogTop: 458px; dialogLeft: 166px; edge: Raised; center: Yes; help: Yes; resizable: Yes; status: Yes;");2.window.close();3.传值ParentPage.aspx:window.showModalDialog("DialogPage.aspx?para1=aaa¶2=bbb");DialogPage.aspx:string str1=Request.QueryString["para1"].toString();string str2=Request.QueryString["para2"].toString();返回值DialogPage.aspx:window.returnValue="aaa";ParentPage.aspx:var str=window.showModalDialog("DialogPage.aspx"); kao,简单呀,有如此多的人回复.如果是散分的话也给我点儿。 原理是焦点必须在open页面上!可以模拟使用一个透明成层挡住,所有控件,在查找当前页面的所有select控件,使用select为disable. JS问题,急,急请各位大侠帮帮忙!!!!!!! js input输入字符串的判断问题 小弱求问一个javascript问题 firefox下document.write输出的内容会单独出现在一个页面上 关于ExtJs内存释放问题 关于下拉框函数问题 如何用JAVASCRIPT实现打字测试的功能? 各位--Netscape下非脚本(windows.open)打开的窗口如何关闭? ext多选框问题 用哪个方法 var str= document.form1.text.value,当text为变量时怎么写? IEWebBrowser后如何关闭页面?
window.showModalDialog("http://www.csdn.net","","dialogWidth:600px;dialogHeight:400px;center:1;scroll:0;help:0;status:0");
</script>
在open出来的子窗口中加入如下代码
window.onblur = function(){self.focus()}
是有限的,比如在MyIE或者TE(腾讯的)中就不能达到效果了。而且,这样的话会有麻烦,当你都不想理会这几个窗口时。我倾向于使用 showModalDialog
http://expert.csdn.net/Expert/topic/2001/2001793.xml?temp=.1702082
http://expert.csdn.net/Expert/topic/1911/1911975.xml?temp=.4667322关于模态窗口(showModalDialog)的专题讨论!
1.模态窗口的打开
2.模态窗口的关闭
3.模态窗口的传递参数。
4.其他。
1.window.showModalDialog("DialogPage.aspx","newwin","dialogHeight: 200px; dialogWidth: 150px; dialogTop: 458px; dialogLeft: 166px; edge: Raised; center: Yes; help: Yes; resizable: Yes; status: Yes;");2.window.close();3.传值
ParentPage.aspx:
window.showModalDialog("DialogPage.aspx?para1=aaa¶2=bbb");DialogPage.aspx:
string str1=Request.QueryString["para1"].toString();
string str2=Request.QueryString["para2"].toString();返回值
DialogPage.aspx:
window.returnValue="aaa";ParentPage.aspx:
var str=window.showModalDialog("DialogPage.aspx");
可以模拟使用一个透明成层挡住,所有控件,在查找当前页面的所有select控件,
使用select为disable.