main.html: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML> <HEAD> <TITLE> New Document </TITLE> <META NAME="Generator" CONTENT="EditPlus"> <META NAME="Author" CONTENT=""> <META NAME="Keywords" CONTENT=""> <META NAME="Description" CONTENT=""> <mce:script language="JavaScript" type="text/javascript"><!-- // function returnFun(){ var returnValue = showConfirm('confirm.html'); if (typeof(returnValue)!="undefined"){ } } //显示弹出页 function showConfirm(url_str){ var returnValue = window.showModalDialog(url_str,null,'dialogLeft:550;dialogTop:400;dialogWidth:0.5px;dialogHeight:0.5px;status:no;resizable: no; scroll:no'); return returnValue; } // --></mce:script> </HEAD> <BODY> <table> <tr><td><input type="button" onClick="returnFun();return false;" value="点我"></td></tr> </table> </BODY> </HTML> confirm.html: