|
Posted by dawnerd on 04/30/07 23:31
On Apr 30, 4:22 pm, Oliver Grätz <oliver.gra...@gmx.de> wrote:
> dawnerd schrieb:
>
> > I have another little problem that I could use some advice on. I have
> > a session class that handles creating a simple session to keep my
> > users logged in. It works fine. However, the session will expire in a
> > random amount of time.
>
> I did not look at the code but I can tell you about one way the expire
> might happen seemingly "randomly": Do you have any other PHP apps
> installed on the server where you are testing your code? They might in
> fact be deleting your sessions! Why? Because the sessions for all PHP
> apps are by defualt stored as files in the same place: The system temp
> dir. This collides with the ability to set the session expiration time
> per application. If you have another app on your server where this time
> is significantly shorter then at any given time a request on this app
> might cause the session data for ALL apps to be cleaned up!
>
> Fix: Use a unique storage location for your app and check if the error
> persists.
>
> OLLi
>
> --
> Bug? That's not a bug, that's a feature.
> [T. John Wendel]
That might be the reason; however, all my applications use the same
classes.
Navigation:
[Reply to this message]
|