3v4l.org

run code in 300+ PHP versions simultaneously
<?php function oeffne($speicherpfad, $session_name) { echo $session_name; return(true); } function schliesse() { echo 'close'; return(true); } function lese($id) { echo 'read'; return ''; } function schreibe($id, $sess_daten) { echo 'write'; return true; } function loesche($id) { echo 'destory'; return true; } function gc($maxlifetime) { echo 'gc'; return true; } session_set_save_handler("oeffne", "schliesse", "lese", "schreibe", "loesche", "gc"); session_start(); session_write_close(); //session_regenerate_id(true); session_set_save_handler("schliesse", "oeffne", "lese", "loesche", "schreibe", "gc"); session_start();
Output for 8.0.0 - 8.0.15, 8.0.17 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.6
PHPSESSID Warning: session_start(): Session cookie cannot be sent after headers have already been sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 readclose Warning: session_start(): Session cache limiter cannot be sent after headers have already been sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 Warning: session_set_save_handler(): Session save handler cannot be changed after headers have already been sent in /in/UA1ts on line 46 Warning: session_start(): Session cannot be started after headers have already been sent in /in/UA1ts on line 48
Output for 8.0.16
PHPSESSID Warning: session_start(): Session cookie cannot be sent after headers have already been sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 readgcclose Warning: session_start(): Session cache limiter cannot be sent after headers have already been sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 Warning: session_set_save_handler(): Session save handler cannot be changed after headers have already been sent in /in/UA1ts on line 46 Warning: session_start(): Session cannot be started after headers have already been sent in /in/UA1ts on line 48
Output for 7.2.0 - 7.2.4, 7.2.6 - 7.2.8, 7.2.10 - 7.2.30, 7.2.32 - 7.2.33, 7.3.0 - 7.3.9, 7.3.11 - 7.3.33, 7.4.0 - 7.4.25, 7.4.27 - 7.4.33
PHPSESSID Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 readclose Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 Warning: session_set_save_handler(): Cannot change save handler when headers already sent in /in/UA1ts on line 46 Warning: session_start(): Cannot start session when headers already sent in /in/UA1ts on line 48
Output for 7.2.5, 7.2.9, 7.2.31, 7.3.10, 7.4.26
PHPSESSID Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 readgcclose Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 Warning: session_set_save_handler(): Cannot change save handler when headers already sent in /in/UA1ts on line 46 Warning: session_start(): Cannot start session when headers already sent in /in/UA1ts on line 48
Output for 7.1.0 - 7.1.15, 7.1.17 - 7.1.33
PHPSESSID Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 readclose Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 close Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 48 read Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 48 Fatal error: Uncaught ArgumentCountError: Too few arguments to function oeffne(), 0 passed and exactly 2 expected in /in/UA1ts:4 Stack trace: #0 [internal function]: oeffne() #1 /in/UA1ts(48): session_start() #2 {main} thrown in /in/UA1ts on line 4
Process exited with code 255.
Output for 7.1.16
PHPSESSID Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 readgcclose Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 close Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 48 read Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 48 Fatal error: Uncaught ArgumentCountError: Too few arguments to function oeffne(), 0 passed and exactly 2 expected in /in/UA1ts:4 Stack trace: #0 [internal function]: oeffne() #1 /in/UA1ts(48): session_start() #2 {main} thrown in /in/UA1ts on line 4
Process exited with code 255.
Output for 5.5.2 - 5.5.27, 5.5.29 - 5.5.38, 5.6.0 - 5.6.6, 5.6.8 - 5.6.20, 5.6.22 - 5.6.40, 7.0.0 - 7.0.33
PHPSESSID Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 read Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 writecloseclose Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 48 read Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 48 destory Warning: Missing argument 1 for oeffne() in /in/UA1ts on line 4 Warning: Missing argument 2 for oeffne() in /in/UA1ts on line 4 Notice: Undefined variable: session_name in /in/UA1ts on line 6
Output for 5.6.7, 5.6.21
PHPSESSID Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 read Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 gcwritecloseclose Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 48 read Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 48 destory Warning: Missing argument 1 for oeffne() in /in/UA1ts on line 4 Warning: Missing argument 2 for oeffne() in /in/UA1ts on line 4 Notice: Undefined variable: session_name in /in/UA1ts on line 6
Output for 5.5.28
PHPSESSID Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 read Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 writecloseclose Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 48 read Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 48 gcdestory Warning: Missing argument 1 for oeffne() in /in/UA1ts on line 4 Warning: Missing argument 2 for oeffne() in /in/UA1ts on line 4 Notice: Undefined variable: session_name in /in/UA1ts on line 6
Output for 5.1.0 - 5.1.6, 5.2.0 - 5.2.11, 5.2.13 - 5.2.17, 5.3.0 - 5.3.29, 5.4.0 - 5.4.45, 5.5.0 - 5.5.1
PHPSESSIDread Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 writeclosecloseread Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 48 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 48 destory Warning: Missing argument 1 for oeffne() in /in/UA1ts on line 4 Warning: Missing argument 2 for oeffne() in /in/UA1ts on line 4 Notice: Undefined variable: session_name in /in/UA1ts on line 6
Output for 5.2.12
PHPSESSIDread Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 gcwriteclosecloseread Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 48 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 48 destory Warning: Missing argument 1 for oeffne() in /in/UA1ts on line 4 Warning: Missing argument 2 for oeffne() in /in/UA1ts on line 4 Notice: Undefined variable: session_name in /in/UA1ts on line 6
Output for 4.3.2 - 4.3.7, 4.3.9 - 4.3.11, 4.4.0 - 4.4.9, 5.0.0 - 5.0.5
PHPSESSIDread Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 writeclosecloseread Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 48 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 48 destory Warning: Missing argument 1 for oeffne() in /in/UA1ts on line 4 Warning: Missing argument 2 for oeffne() in /in/UA1ts on line 4
Output for 4.3.8
PHPSESSIDread Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 writeclosecloseread Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 48 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 48 gcdestory Warning: Missing argument 1 for oeffne() in /in/UA1ts on line 4 Warning: Missing argument 2 for oeffne() in /in/UA1ts on line 4
Output for 4.3.0 - 4.3.1
PHPSESSIDread Warning: session_start() [http://www.php.net/function.session-start]: Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 42 Warning: session_start() [http://www.php.net/function.session-start]: Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 42 writeclosecloseread Warning: session_start() [http://www.php.net/function.session-start]: Cannot send session cookie - headers already sent by (output started at /in/UA1ts:6) in /in/UA1ts on line 48 Warning: session_start() [http://www.php.net/function.session-start]: Cannot send session cache limiter - headers already sent (output started at /in/UA1ts:6) in /in/UA1ts on line 48 destory Warning: Missing argument 1 for oeffne() in /in/UA1ts on line 4 Warning: Missing argument 2 for oeffne() in /in/UA1ts on line 4

preferences:
315.02 ms | 403 KiB | 460 Q