3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array ( 0 => array ( 'one' => 'A {bad} thing.', 'two' => 'So far so {bad}.', ), 1 => array ( 'one' => 'A {bad} thing, bis.', 'two' => 'So far so {bad}, bis.', ), ); $b = str_replace('{bad}', 'good', $a); echo '$b = '; var_export($b); echo ';', "\n";
based on ED1hB