<body>元素添加unload

2017-06-19 11:01:00
admin
原创
533
<!DOCTYPE html>
<html>
<head>
    <title>Unload Event Example</title>
    <script type="text/javascript" src="http://code.ybao.org/demo/js/EventUtil.js"></script>
</head>
<body>
    <p>Unload event example - navigate to another page or close this tab/window to fire the event.</p>
    <script type="text/javascript">
        EventUtil.addHandler(window, "unload", function(event){
            alert("Unloaded");
        });
    </script>
</body>
</html>
  • QQ讨论群
  • 关注微信
    • 欢迎咨询
    • 欢迎加入QQ群 16506021
  • 公众号:源宝网络