当前位置:开发者网络 >> 网页特效 >> 综 合 类 >> 内容
精彩推荐
分类最新特效
分类热点特效
  
检查窗口的关闭打开
日期:2005-07-01   人气:   【字体: 】【收藏此文


<!-- 网页特效代码由[中国WEB开发者网络:http://www.ChinaWebDev.com]提供! -->
<!-- 要实现此效果需要 1 个步骤: -->

<!-- 第 1 步: -->
<!-- 把下面的代码加到<BODY></BODY>区域中: -->

<script>
var newwin
function makenewwin() {
newwin=window.open("","vv","height=300,width=200")
newwin.document.writeln("ok")
newwin.document.close()
}
function check() {
if (newwin&&newwin.open&&!newwin.closed){
alert("开的")
}
else{
alert("关的")
}
}
</script>
<input type="button" value="open" onclick="makenewwin()">
<input type="button" value="检查" onclick="check()">