hi all
i have searched a lot but could not find the solution.
i am facing trouble in calling function on window unload.
Code:
<script language="javascript">
window.onunload = function()
{
alert("bye");
}
</script>
i want to call this script only when the user closes the browser tab. but i m getting this alert on every refresh and when i leave this page and go to another page.
how can i get this alert only when i close the browser tab. i want to show this message to user when he exit or close the website.
vineet
|