Click here to Skip to main content
15,888,081 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i have tried onunload and onbeforeunload in body tag of my master page but its not working when i have clicked the link on usercontrol as menu and also not working if refresh the browser.

how can i aware that the browser is gettig close on serverside???
Posted
Comments
Kornfeld Eliyahu Peter 22-Oct-14 7:06am    
But how if you can not run a simple search!
This question was answered here in CP 2-3 time in the last year alone, how that you were unable to find them? Oh! I see! Didn't looked for!
AddyRuno 22-Oct-14 7:15am    
i have applied all ... but not working... :/
Kornfeld Eliyahu Peter 22-Oct-14 7:18am    
Applied what?! All that answers are speaking about that there is no sure solution - there are ways that will work in some cases but because of the disconnected nature of the web it can not be done in all cases...

1 solution

please check the link

How to end user session when browser closed[^]

Hope it will help you.
 
Share this answer
 
Comments
AddyRuno 22-Oct-14 7:19am    
this solution is not working when i close the browser , i am using firefox.
Kornfeld Eliyahu Peter 22-Oct-14 7:20am    
When you read an article - start with the first line!!! Always!
IpsitaMishra 22-Oct-14 7:26am    
Can you Please debug and check what is the issue.
AddyRuno 22-Oct-14 8:04am    
Simply its not going to the logout.aspx page when i close the browser
IpsitaMishra 22-Oct-14 8:08am    
Is it calling the unload function or not..

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900