FF是不行的,FF不允许脚本关闭非脚本打开的窗口。

解决方案 »

  1.   

    firefox需要使用
    about:config修改配置
    ie7不能去掉提示
      

  2.   

    孟子大哥都来回帖了,真感动!!恩,我研究过在IE7不用用js的方式无提示关闭窗口,后来找了另一种办法实现了
    <object id="WebBrowser" width=0 height=0 classid="CLSID:8856F961-340A-11D0-A96B-00C04FD705A2">
    <input type="button" name="Button" value="关闭窗口" onClick="document.all.WebBrowser.ExecWB(45,1)">
      

  3.   

     <input type="button" value="close" onclick="window.close();" />
    不管在IE7还是在FF里都没有出现楼主说的问题,操作都很顺利
      

  4.   

    经验证
    IE: js关闭非window.open的窗口时会出现询问对话框。
    FF: 不允许js关闭非window.open的窗口,代码不响应。解决方法关注中
      

  5.   

    firefox
    about:config
    ie7不行
      

  6.   

    IE7也可以做的
    http://blog.csdn.net/hbhbhbhbhb1021/archive/2007/11/16/1888282.aspx
      

  7.   

    window.opener=null;
    window.open('','_top');
    window.top.close();
      

  8.   

    IE8里面用window.close()的提示信息:
    ---------------------------
    来自网页的消息
    ---------------------------
    Stack overflow at line: 729
    ---------------------------
    确定   
    ---------------------------