Zend framework session expires prematurely

前端 未结 5 972
既然无缘
既然无缘 2020-12-14 21:28

I\'m using Zend Framework for PHP and handling sessions with the Zend_Session module. This is what I have in my Initializer (or bootstrap):

Zend_Session::st         


        
5条回答
  •  难免孤独
    2020-12-14 21:52

    I had the same problem and solved it by putting:

    resources.session.save_path = APPLICATION_PATH "/../data/session/"
    resources.session.gc_maxlifetime = 864000
    resources.session.remember_me_seconds = 864000
    

    in the application.ini (as suggested by tawfekov) and

    protected function _initSessions() {
        $this->bootstrap('session');
    }
    

    in the Bootstrap.php (this I typically forgot at first). You have to give the session directory the correct access rights (chmod 777). I described the issue here. Hopefully this will help the next person with the same issue.

提交回复
热议问题