Refactored double Set-Cookie prevention code, and session reopening code
This commit is contained in:
parent
91c584ba16
commit
8b6833180d
8 changed files with 30 additions and 22 deletions
|
@ -34,14 +34,8 @@ class LoginController extends Zend_Controller_Action
|
|||
|
||||
if (Zend_Session::isStarted()) {
|
||||
|
||||
ini_set('session.use_only_cookies', false);
|
||||
ini_set('session.use_cookies', false);
|
||||
ini_set('session.use_trans_sid', false);
|
||||
ini_set('session.cache_limiter', null);
|
||||
session_start(); // second session_start
|
||||
|
||||
//Open the session for writing, because we close it for writing by default in Bootstrap.php as an optimization.
|
||||
//session_start();
|
||||
SessionHelper::reopenSessionForWriting();
|
||||
|
||||
$auth = Zend_Auth::getInstance();
|
||||
$auth->getStorage();
|
||||
|
@ -142,7 +136,7 @@ class LoginController extends Zend_Controller_Action
|
|||
public function logoutAction()
|
||||
{
|
||||
//Open the session for writing, because we close it for writing by default in Bootstrap.php as an optimization.
|
||||
session_start();
|
||||
SessionHelper::reopenSessionForWriting();
|
||||
|
||||
$auth = Zend_Auth::getInstance();
|
||||
$auth->clearIdentity();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue