Can you please tell me how to expire a session after a fixed interval of time.(i.e if the browser is inactive for some time - say, 5 mins)
Once the session expires, and if user tries to access the page, then he is prompted for login again, am i right?
Please tell me how to solve this problem.
Thank you.
nikk 0 Light Poster
Recommended Answers
Jump to PostTo have it expired automatically, you need to configure the Application Server/Web Container properly.
Reading the session properly, and redirecting to a login page, is something you will have to do though.
The above command is the one the server will use, you can use it yourself, as …
Jump to Postin fact, all sessions will expire automatically at the rate set in the server/web app configuration.
And while there are ways to do it manually, using timers and threads in the application, why would you want to essentially replicate functionality the server provides for you?
Jump to Postthere are ways to do it manually, using timers and threads in the application
Correct, of course, I should have said
but it is not practical for your classes to automatically expire the session
instead of
but your classes will not be able to automatically expire the …
Jump to PostA directive to the browser and/or proxy server not to hold a cached copy of the page. Nothing to do with a session.
Edit: Or, more correctly, that whatever cached copy they do hold is invalid as soon as they made it, and they should retrieve a fresh copy …
All 13 Replies
mostafadotnet 18 Junior Poster
nikk 0 Light Poster
vedmack 0 Junior Poster in Training
masijade 1,351 Industrious Poster Team Colleague Featured Poster
jwenting 1,905 duckman Team Colleague
masijade 1,351 Industrious Poster Team Colleague Featured Poster
nikk 0 Light Poster
masijade 1,351 Industrious Poster Team Colleague Featured Poster
nikk 0 Light Poster
masijade 1,351 Industrious Poster Team Colleague Featured Poster
nikk 0 Light Poster
masijade 1,351 Industrious Poster Team Colleague Featured Poster
nikk 0 Light Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.