Hi all,
I am building a web application with B4J Server (non-ui) and ABMaterial - so it's a websockets web app and I am wondering how you handle user logins and logouts in your web app.
So let's take the following scenario:
1. user signed in -> save the username in the session -> redirect the user to the initial page of the app
2. the user duplicates the tab in browser so now he has two tabs logged in the app with the same session, but different websockets
3. the user clicks the sign out button from tab1 -> remove the username from session -> redirect to the login page of app
4. what about the tab2 ? it doesn't get redirected to the login page and still I can click buttons in the page ... i have to refresh the page manually so tab2 gets redirected to the login page.
How can i auto redirect the other tabs that the user may have created when the user click the sign out button in one tab ?!
I am building a web application with B4J Server (non-ui) and ABMaterial - so it's a websockets web app and I am wondering how you handle user logins and logouts in your web app.
So let's take the following scenario:
1. user signed in -> save the username in the session -> redirect the user to the initial page of the app
2. the user duplicates the tab in browser so now he has two tabs logged in the app with the same session, but different websockets
3. the user clicks the sign out button from tab1 -> remove the username from session -> redirect to the login page of app
4. what about the tab2 ? it doesn't get redirected to the login page and still I can click buttons in the page ... i have to refresh the page manually so tab2 gets redirected to the login page.
How can i auto redirect the other tabs that the user may have created when the user click the sign out button in one tab ?!