I'm running a Magento based website store on Linux/Apache.
In order that user logins are maintained, I've set my cookie lifetime to be close to two years. The cookies are sent out with the right times, I can see them in my browsers. When I visit the site from a previously logged-in browser after about a day, the user is logged out. I can 开发者_如何学JAVAstill see the cookies, with their extended life, present in the browser.
Where should I start looking to get to the bottom of this issue?
Have you checked the value of PHP's session.gc_maxlifetime parameter? Regardless of the life that Magento allows, this lifetime setting will still kill cookies after a little while. In your .htaccess file in the magento directory, add this:
php_value session.gc_maxlifetime 31536000
That may solve the problem.
Hope that helps!
Thanks, Joe
精彩评论