I want browser tab to show an alert message as soon as it is clicked to close .Here is the full code that i am trying in HTML page..
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<script src="js/jquery-1.7.1.js" type="text/javascript"></script>
<script type="text/javascript">
$( window ).unload(function() {
alert( "Bye now!" );
});
</script>
</head>
<body>
</body>
But on closing browser tab i am not getting any type of alert message ..Please help me ..