3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $full_text = "This is a test :) :D It's a boring test."; $body = $full_text; $body = nl2br($body); $body = str_replace( array(':)', ':D', '[b]', '[/b]), array('Emoticon Smile', 'Emoticon colon D', '<b>', '</b>'), $body ); echo $body;
Output for 5.4.0 - 5.4.21
Parse error: syntax error, unexpected 'Emoticon' (T_STRING), expecting ')' in /in/XiGXA on line 15
Process exited with code 255.
Output for 5.3.0 - 5.3.27
Parse error: syntax error, unexpected T_STRING, expecting ')' in /in/XiGXA on line 15
Process exited with code 255.