Skip to Content (Press Enter)
OutSystems.com
Personal Edition
Community
Support
Training
Training
Online Training
Developer Schools
Boot Camps
Certifications
Tech Talks
Documentation
Documentation
Overview
ODC
O11
Forums
Forge
Get Involved
Get Involved
Jobs
Ideas
Members
Mentorship
User Groups
Platform
Platform
ODC
O11
Search in OutSystems
Log in
Get Started
Back to Forums
Frank
17
Views
1
Comments
Using the onunload javascript function to force a log off of app
Question
Hello Everyone,
I have another javascript question with Outsystems. I want my app to log off automatically when a user exits the browser without pressing the LogOut button that I have coded in the app. How do I implement that by using the onunload function or perhaps another technique that is easier?
Frank
António Chinita
Frank wrote
:
Hello Everyone,
I have another javascript question with Outsystems. I want my app to log off automatically when a user exits the browser without pressing the LogOut button that I have coded in the app. How do I implement that by using the onunload function or perhaps another technique that is easier?
Frank
Hi Frank.
What you need should actually be happening by default.
Did you build your custom login? If so, check if you aren't setting the "Remember" variable to True.
Remember this works only when you exit the browser. It won't work if you simply close the Browser Tab without fully closing the browser.
Javascript's OnUnload is tricky to use, and you should avoid it whenever possible.
For example, it will trigger for every Navigate or Submit button.
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
See the full guidelines
Loading...