我使用unload 这个方法,用opera刷新页面还是不没反应,请教下大家 还有什么方法代替onbeforeunload属性,执行这个代码,刷新窗口 浏览器不提示<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>onunload测试</title>
<script>
function checkLeave(){
alert("欢迎下次再来!");
}
</script>
</head>
<body onunload="checkLeave()">
</body>
</html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>onunload测试</title>
<script>
function checkLeave(){
alert("欢迎下次再来!");
}
</script>
</head>
<body onunload="checkLeave()">
</body>
</html>
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货