We are using asp.net StateServer for asp.net session management. In our project we need to make sure that if a user is already logged in and if he is trying to acess the website from a different browser tab, we need to inform him that he is already logged in in another tab and use it instead of opening a new session. Consider the following scenarios:
1. User is logged on in tab1 and his session is still on, then user tries to logon from another tab, the browser sends the asp.net session_id cookie, In the page init i am checking if the Asp.net session Id cookie is present, if it is there i am checking if the it is a new Session (i.e. if the existing session timed out), if it is a new session then proceed with the user action else it means that the session in tab1 is still active so i am redirecting user to error page with appropriate message.
Now the problem with this approach is that, suppose session in tab1 is expired and user opens tab2 and performs some actions, now he goes back to tab1 and perform any action, i directly need to take him to log out page.
Please let me know how this can be achieved.
View Complete Post