3v4l.org

run code in 300+ PHP versions simultaneously
<?php function parse($args) { $jobArgs = []; $list = explode(',', $args); foreach ($list as $item) { $splitArg = explode('=', $item); $jobArgs[$splitArg[0]] = $splitArg[1]; } return $jobArgs; } function parse2($args) { $jobArgs = []; $list = str_replace(',', '&', $args); parse_str($list, $jobArgs); return $jobArgs; } var_dump(parse("one=test,two=another,three=win")); var_dump(parse2("one=test,two=another,three=win"));
Output for git.master, git.master_jit, rfc.property-hooks
array(3) { ["one"]=> string(4) "test" ["two"]=> string(7) "another" ["three"]=> string(3) "win" } array(3) { ["one"]=> string(4) "test" ["two"]=> string(7) "another" ["three"]=> string(3) "win" }

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