Symfony\Component\HttpFoundation\Session::getId PHP Метод

getId() публичный Метод

Returns the session ID
public getId ( ) : mixed
Результат mixed The session ID
    public function getId()
    {
        if (false === $this->started) {
            $this->start();
        }

        return $this->storage->getId();
    }

Usage Example

Пример #1
0
 /**
  * Returns the ID of the user session
  *
  * Automatically starts the session if necessary.
  *
  * @return string  The session ID
  */
 protected function getSessionId()
 {
     return $this->session->getId();
 }