3v4l.org

run code in 300+ PHP versions simultaneously
<?php class FileSessionHandler { private $savePath; function open($savePath, $sessionName) { return true; } function close() { return true; } function read($id) { return 'lol|s:222:"1";lol2|s:1:"1";'; } function write($id, $data) { } function destroy($id) { } function gc($maxlifetime) { } } $handler = new FileSessionHandler(); session_set_save_handler( array($handler, 'open'), array($handler, 'close'), array($handler, 'read'), array($handler, 'write'), array($handler, 'destroy'), array($handler, 'gc') ); register_shutdown_function('session_write_close'); session_start(); var_dump($_SESSION);
Output for git.master, git.master_jit, rfc.property-hooks
Warning: session_start(): Failed to decode session object. Session has been destroyed in /in/tWYcZ on line 50 Fatal error: Uncaught TypeError: Session callback must have a return value of type bool, null returned in /in/tWYcZ:50 Stack trace: #0 /in/tWYcZ(50): session_start() #1 {main} thrown in /in/tWYcZ on line 50
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
56.99 ms | 401 KiB | 8 Q