In my MVC app, i am trying to capture some user info when the user is closing the browser window. My page also has a webgrid with pagination. I have tried using:
$(window).unload(function()
but the problem that i am facing is that whenever a user navigates to a different page of the webgrid, the .unload function fires off too. I am trying to find a way to fire off the .unload function only at the time of closing the browser window. Thank you.