The Note You're Voting On
polygon dot co dot in at gmail dot com ¶ 1 year ago
<?php
session_start([
'read_and_close' => true,
]);
?>
The read_and_close option I believed was to work as a read only mode session
To the surprise it works even if no sessionId cookie is present in the http request and generates a new sessionId.
Secondly, the function with this option also generates new session files with respect to the newly generated sessionId
Third, if the sessionId is invalid (no file is present with respect to sessionId) it creates a new one.