Web lists-archives.com

[PHP] Cannot make use_strict_mode work with custom session handler upon 'files'

I want to implement custom session handler upon internal files handler similar to this: http://php.net/manual/en/class.sessionhandler.php#example-5380 (example 1).

But with session.use_strict_mode = 1.

I have been trying to test this sample code, but I can't seem to get it to work:

ini_set('session.use_strict_mode', '1');

class MySessionHandler extends SessionHandler{}
session_set_save_handler(new MySessionHandler(), true);


After delete an existing session file and rerun script, it create new file with the same id.

When there is no session_set_save_handler() it works as expected: new file is created with new id.

I suppose that it is a bug, but maybe there is a solution that I can't see.

PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php