3v4l.org

run code in 300+ PHP versions simultaneously
<?php session_start(); $_SESSION = array('a' => 5, 'b' => 'ee', 'c' => 55); var_dump($_SESSION); $str = session_encode(); var_dump($str); $str = str_replace('e', 'é', $str); var_dump($str); $_SESSION = array(); var_dump($_SESSION); session_decode($str); var_dump($_SESSION); $str = session_encode(); var_dump($str);
Output for git.master, git.master_jit, rfc.property-hooks
array(3) { ["a"]=> int(5) ["b"]=> string(2) "ee" ["c"]=> int(55) } string(24) "a|i:5;b|s:2:"ee";c|i:55;" string(26) "a|i:5;b|s:2:"éé";c|i:55;" array(0) { } Warning: session_decode(): Failed to decode session object. Session has been destroyed in /in/gTNYb on line 11 array(0) { } bool(false)

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:
37.48 ms | 401 KiB | 8 Q