|
|
1.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"><HTML> <HEAD> <TITLE> New Document </TITLE> </HEAD><script>function openchild(){ x=window.showModalDialog("2.html",window,"dialogHeight:200px;dialogWidth:400px;center:yes;help:No;resizable:No;status:No;");closeChild();}function closeChild(){alert("子窗口已经关闭");}</script> <BODY> <input type="button" value="点我打开子页面" > </BODY></HTML>
2.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"><HTML> <HEAD> <TITLE> New Document </TITLE> </HEAD> <frameset rows="0,*"> <frame src="about:blank"> <frame src="http://www.sina.com"> </frameset></HTML>
showModalDialog()、showModelessDialog()方法使用详解:
http://blog.csdn.net/net_lover/archive/2002/09/24/6910.aspx |
|