3v4l.org

run code in 300+ PHP versions simultaneously
<?php $superheroes = array( "spider-man" => array( "name" => "Peter Parker", "email" => "peterparker@mail.com", ), "super-man" => array( "name" => "Clark Kent", "email" => "clarkkent@mail.com", ), "iron-man" => array( "name" => "Harry Potter", "email" => "harrypotter@mail.com", ) ); //print_r($superheroes); function checkArray($array) { forEach($array as $index => $item) { $dimensionPath = $array . $index; if(is_Array($item)) { echo "========== \n"; //$dimensionPath = $array . $index; echo "YES-" . $dimensionPath . ": " . $item . "\n"; checkArray($item); } else { echo "NO-" . $dimensionPath . ": " . $item . "\n"; } } } checkArray($superheroes);
Output for git.master, git.master_jit, rfc.property-hooks
Warning: Array to string conversion in /in/UBuU1 on line 21 ========== Warning: Array to string conversion in /in/UBuU1 on line 25 YES-Arrayspider-man: Array Warning: Array to string conversion in /in/UBuU1 on line 21 NO-Arrayname: Peter Parker Warning: Array to string conversion in /in/UBuU1 on line 21 NO-Arrayemail: peterparker@mail.com Warning: Array to string conversion in /in/UBuU1 on line 21 ========== Warning: Array to string conversion in /in/UBuU1 on line 25 YES-Arraysuper-man: Array Warning: Array to string conversion in /in/UBuU1 on line 21 NO-Arrayname: Clark Kent Warning: Array to string conversion in /in/UBuU1 on line 21 NO-Arrayemail: clarkkent@mail.com Warning: Array to string conversion in /in/UBuU1 on line 21 ========== Warning: Array to string conversion in /in/UBuU1 on line 25 YES-Arrayiron-man: Array Warning: Array to string conversion in /in/UBuU1 on line 21 NO-Arrayname: Harry Potter Warning: Array to string conversion in /in/UBuU1 on line 21 NO-Arrayemail: harrypotter@mail.com

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:
45.45 ms | 403 KiB | 8 Q