什么意思 ?
 if(aa!= null)

解决方案 »

  1.   

    一个窗口名称为aa,我要知道它是否存在。
    aa窗口可能是用window.name='aa';或window.open()来创建的。
      

  2.   

    var a = window.open("a.html");
    a ? alert("存在") : alert("不存在");
      

  3.   

    var talkWindow = null;
    function win_open(sUrl,nUin){
    if(talkWindow && talkWindow.open && !talkWindow.closed){
    alert(msg_Talk);
    }else{
        talkWindow=window.open(sUrl,"TalkWin","width=611,height=471");
    }
    }
      

  4.   

    var a = window.open("a.html");
    a ? alert("存在") : alert("不存在");
      

  5.   

    父窗口可以判断子窗口。其他是不可能的,再高的高手也解决不了。因为javascript的安全性能是不允许他跨窗口访问的(在客户端安装插件除外)。
      

  6.   

    那能不能子窗口控制父窗口居顶(focus())
      

  7.   

    这个,JK前辈貌似写过<script type="text/javascript">
    window.setTimeout(function () {
    window.open('about:blank', 'aa'); //把这一行注释掉,就可以看到不存在的效果

    window.open('javascript:document.body ? (alert("存在"),(location.href="about:blank")) : (alert("不存在"),(location.href="about:blank"));','aa');
    },0);
    </script>重新给你写了段,你可以测试下...^^
      

  8.   

    重新贴下...<script type="text/javascript">
    window.setTimeout(function () {
    window.open('about:blank', 'aa'); //把这一行注释掉,就可以看到不存在的效果

    window.open('javascript:document.body ? (alert("存在"),(location.href="about:blank")) : (alert("不存在"),(location.href="about:blank"));','aa');
    },0);
    </script>