3v4l.org

run code in 300+ PHP versions simultaneously
<?php $article = '"foo bar baz" bat "quux quuz" this little "piggy" went "to market, this little" piggy "STAYED HOME!"'; $article_clean = preg_replace_callback('/".*?"/', function($v) { return str_replace(' ', '&nbsp;', $v[0]); }, $article); var_dump($article_clean);
Output for git.master, git.master_jit, rfc.property-hooks
string(135) ""foo&nbsp;bar&nbsp;baz" bat "quux&nbsp;quuz" this little "piggy" went "to&nbsp;market,&nbsp;this&nbsp;little" piggy "STAYED&nbsp;HOME!""

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:
33.26 ms | 401 KiB | 8 Q