3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class myProcess { function __construct($sameArray){ $mySentence = json_encode($sameArray); $mySentence = preg_replace('/o/','t',$mySentence); $otherArray = json_decode($mySentence); print($otherArray); //this is line 45 //print($mySentence); //$placements = array ("John" => "Jose", "Smith" => "Tobar"); // preg_replace("/:(\w+)/e", $placements[$1], $mySentence); } } ?>
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0