3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $text_string = '+TEST+'; $text = explode("+", $text_string); $text = $text[1]; $replaced_text = str_replace("+$text+", "<em>$text</em>", $text_string); echo $replaced_text; // output: <em>TEST</em> ?>
Output for 4.3.0 - 7.2.0
<em>TEST</em>