易截截图软件、单文件、免安装、纯绿色、仅160KB

javaScript关闭浏览器 (不弹出提示框)

<script language="javaScript">
function closeWindow()
{
 window.opener = null;
 window.open(' ', '_self', ' ');
 window.close();
}
</script>
<input type='button' value='关闭窗口' onClick="closeWindow()">

<input type="button" value="关闭窗口" onClick="window.opener = null;
window.open(' ', '_self', ' ');window.close()">
对于关闭框架窗口
<script language="javaScript">
function closeWindow()
{
window.opener = null;
window.open('', '_top', '');
window.parent.close();
}
</script>


相关文档:

JavaScript学习笔记(六)

1.DOM是针对XML的基于树的API。使用DOM,只需解析代码一次来创建一个树的模型。在这个初始解析过程之后,XML已经完全通过DOM模型表现出来,同时也不再需要原始的代码。
   NB
:DOM是语言无关的API,它并不与Java、JavaScript或其他语言绑定。 ......

[翻译]High Performance JavaScript(007)

Dynamic Scopes  动态作用域
    Both the with statement and the catch clause of a try-catch statement, as well as a function containing eval_r(), are all considered to be dynamic scopes. A dynamic scope is one that exists only through execution of code and therefore cannot be det ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号