If we close the tab or browser directly then the session and cookies should automatically be cleared. So that the person has to log in again.
And when and where to implement this logic?
Hi Sumant,
You can refer below link hope it will help you
https://www.outsystems.com/forums/discussion/53010/end-session-when-user-closes-the-tab-or-browser-without-logging-out/#:~:text=we%20can%20find%20the%20tab,by%20clicking%20on%20logout%20icon.
Regards,
Krushna
No from this, it is not possible. Without clicking on logout I want to clear the session and cookies.
If you somehow figure out that you could clear the session when the user is clicking on close tab button, how are you going to deal with the fact that there may be other tabs open for your same application?
The users using multiple tabs may not expect their login session to be cleared by just closing one of the tabs. Your strategy won't bring a good user experience. You can try thinking some more creatively and find some other way to achieve your desired expectation from the app, which also comforts the user experience.
I want to clear my session. How I can do it? and where.
You can clear your session after user logs out from the application. Or else if you want user session to end after closing the window then you can apply logic on 'On Destroy' event of the screen. But it is not the ideal way of doing it