语法 window.open("地址")
功能:打开一个新的窗口
这个新窗口是可以进行设置的
width:窗口宽度 heght:高度 left:窗口x轴坐标 top:窗口y坐标
toolbar:是否显示浏览器工具栏 menubar:是否显示菜单栏
scrollbars:是否显示滚动条 location:是否显示地址字段
status:是否添加状态栏
语法:
<input type="button" name="" value="打开页面"> <script> var a=document.getElementsByTagName("input")[0]; a.onclick=function(){ var b=confirm("是否打开页面?") if (b==true){ window.open('99.html','九九乘法表','width=300,height=300,location=no,menubar=no,scrollbars=no,status=no') }else { window.close(); } } </script>