2010年6月4日星期五

[fw-mvc] Session lifetime

I am confused about Zend_Session's lifetime option.

If I want to remember a user for a long time, Could I just set the option to a time I expect, and It will work? But this means the server will keep the data for that time,right?

I recall that in Java, there is an expire option for session. The value for that option is not big normally, if I want to remember a user, I write some data to cookie. When user close browser, the session will expire after expire time I set. And next time when user visit my site, the server will read it's cookie data and turn it to session.

Which way is better and safer?








--
Location:

没有评论: