3v4l.org

run code in 300+ PHP versions simultaneously
<?php $parameters = "userOnline=now, userName=- week"; $parametersString = explode(', ', $parameters); $parametersArray = array(); array_walk($parametersString, 'walk'); function walk(&$val, $key, $new_array){ $nums = explode('=', $val); $new_array[$nums[0]] = $nums[1]; } print_r($new_array);
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught ArgumentCountError: Too few arguments to function walk(), 2 passed and exactly 3 expected in /in/RJnrt:7 Stack trace: #0 [internal function]: walk('userOnline=now', 0) #1 /in/RJnrt(5): array_walk(Array, 'walk') #2 {main} thrown in /in/RJnrt on line 7
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:
63.48 ms | 401 KiB | 8 Q