protected SessionManager::startNow()
Forcibly start a PHP session.
bool TRUE if the session is started.
protected function startNow() { if ($this->isCli()) { return FALSE; } if ($this->startedLazy) { // Save current session data before starting it, as PHP will destroy it. $session_data = $_SESSION; } $result = parent::start(); // Restore session data. if ($this->startedLazy) { $_SESSION = $session_data; $this->loadSession(); } return $result; }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Session!SessionManager.php/function/SessionManager::startNow/8.1.x