3v4l.org

run code in 300+ PHP versions simultaneously
<?php $data = 'a:3:{ i:0;a:4: {s:8:"min_days";s:1:"1";s:8:"max_days";s:1:"1";s:10:"range_cost";s:2:"340";s:15:"cost_applicable";s:5:"fixed";} i:1;a:4: {s:8:"min_days";s:1:"2";s:8:"max_days";s:1:"2";s:10:"range_cost";s:2:"450";s:15:"cost_applicable";s:5:"fixed";} i:2;a:4: {s:8:"min_days";s:1:"3";s:8:"max_days";s:1:"3";s:10:"range_cost";s:2:"570";s:15:"cost_applicable";s:5:"fixed";}}'; $data = str_replace("\n", "", $data); $fixed_data = preg_replace_callback ( '!s:(\d+):"(.*?)";!', function($match) { return ($match[1] == strlen($match[2])) ? $match[0] : 's:' . strlen($match[2]) . ':"' . $match[2] . '";'; }, $data ); print_r(unserialize($fixed_data));
Output for git.master, git.master_jit, rfc.property-hooks
Array ( [0] => Array ( [min_days] => 1 [max_days] => 1 [range_cost] => 340 [cost_applicable] => fixed ) [1] => Array ( [min_days] => 2 [max_days] => 2 [range_cost] => 450 [cost_applicable] => fixed ) [2] => Array ( [min_days] => 3 [max_days] => 3 [range_cost] => 570 [cost_applicable] => fixed ) )

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:
33.32 ms | 407 KiB | 5 Q