SessionHandlerInterface::close

(PHP 5 >= 5.4.0, PHP 7, PHP 8)

SessionHandlerInterface::closeЗакрывает сессию

Описание

public SessionHandlerInterface::close(): bool

Закрывает текущую сессию. Эта функция автоматически выполняется при закрытии сессии или явно через session_write_close().

Список параметров

У этой функции нет параметров.

Возвращаемые значения

Возвращаемое значение сессионного хранилища (обычно true в случае успешного выполнения, false в случае ошибки). Это значение возвращается обратно в PHP для внутренней обработки.

add a note add a note

User Contributed Notes 1 note

up
3
svenr at selfhtml dot org
10 years ago
This method should release the exclusive lock that was acquired by the open() method.

Note that this will effectively serialize parallel requests, which affects performance for a single user session.

Not locking the resource would on the other hand allow for race conditions if two or more parallel requests change the session data.
To Top