复制代码 代码如下:
<script language="javascript">
window.onbeforeunload = function () {
var n = window.event.screenX - window.screenLeft;
var b = n > document.documentElement.scrollWidth - 20;
if (b && window.event.clientY < 0 || window.event.altKey) {
try {
var xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
xmlhttp.open("POST", "LogOut.aspx", false);
xmlhttp.send();
//return true;
}
catch (e) {
alert('delete user account error message:' + e.message);
}
//return "你确定要退出系统吗?退出请按'离开此页'";
} else {
//alert("是刷新而非关闭");
}
}
</script>
<script language="javascript">
window.onbeforeunload = function () {
var n = window.event.screenX - window.screenLeft;
var b = n > document.documentElement.scrollWidth - 20;
if (b && window.event.clientY < 0 || window.event.altKey) {
try {
var xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
xmlhttp.open("POST", "LogOut.aspx", false);
xmlhttp.send();
//return true;
}
catch (e) {
alert('delete user account error message:' + e.message);
}
//return "你确定要退出系统吗?退出请按'离开此页'";
} else {
//alert("是刷新而非关闭");
}
}
</script>
标签:
关闭判断,ajax注销
免责声明:本站文章均来自网站采集或用户投稿,网站不提供任何软件下载或自行开发的软件!
如有用户或公司发现本站内容信息存在侵权行为,请邮件告知! 858582#qq.com
桃源资源网 Design By www.nqtax.com
暂无“IE关闭时判断及AJAX注销案例学习”评论...