Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
Thread: Session Question
04-03-2003, 11:50 AM #1
- Join Date
- Sep 2002
- Thanked 0 Times in 0 Posts
I'm using sessions on an Intranet with MySql based authentication.
A user will quite happily not encounter an error with the session if they use the internal links. (if there is an error, a please log-in again page appears).
If, however, they click a link that opens in a new window, close the new window then try to continue browsing the intranet, the session is gone and they get the login message. This also happens if they click a link to try to download a file.
What can I do/change to prevent this happening?
I've read a thread about using cookies instead of sessions, but at the moment I know even less about cookies then I do about sessions.
04-03-2003, 01:41 PM #2
- Join Date
- May 2002
- Perth Australia
- Thanked 101 Times in 99 Posts
If a user closes ALL browser windows then the session will be lost (by default) .. you can use
which will extend the life of the session beyond the closing of the browser window , though garbage collection limits the true 'useful' life of the session cookie.
If you are saying that the user is not closing all windows but still losing the session then its real hard to guess what the exact problem is, I assume that all pages that require sessions use session_start() in the script ?
MVC is the current buzz in web application architectures. It comes from event-driven desktop application design and doesn't fit into web application design very well. But luckily nobody really knows what MVC means, so we can call our presentation layer separation mechanism MVC and move on. (Rasmus Lerdorf)