3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $fileContent = '12em\n1.3 em'; preg_replace('/([0-9,-\.]+)\s*(em)/e', floatval('\1') * 123 . 'em', $fileContent);
Output for 7.0.0 - 7.1.0
Warning: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead in /in/U2CeE on line 3
Output for hhvm-3.12.0
Fatal error: Uncaught Error: syntax error, unexpected T_STRING in :1 Stack trace: #0 /in/U2CeE(3): include() #1 {main}
Process exited with code 255.
Output for hhvm-3.10.0
Fatal error: syntax error, unexpected T_STRING
Process exited with code 255.
Output for 5.5.0 - 5.6.25
Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /in/U2CeE on line 3 Parse error: syntax error, unexpected 'em' (T_STRING) in /in/U2CeE(3) : regexp code on line 1 Fatal error: preg_replace(): Failed evaluating code: 0em in /in/U2CeE on line 3
Process exited with code 255.
Output for 5.4.0 - 5.4.45
Parse error: syntax error, unexpected 'em' (T_STRING) in /in/U2CeE(3) : regexp code on line 1 Fatal error: preg_replace(): Failed evaluating code: 0em in /in/U2CeE on line 3
Process exited with code 255.
Output for 5.1.0 - 5.3.29
Parse error: syntax error, unexpected T_STRING in /in/U2CeE(3) : regexp code on line 1 Fatal error: preg_replace(): Failed evaluating code: 0em in /in/U2CeE on line 3
Process exited with code 255.
Output for 4.3.11 - 4.4.1, 5.0.0 - 5.0.5
Parse error: parse error, unexpected T_STRING in /in/U2CeE(3) : regexp code on line 1 Fatal error: preg_replace(): Failed evaluating code: 0em in /in/U2CeE on line 3
Process exited with code 255.
Output for 4.4.2 - 4.4.9
Parse error: syntax error, unexpected T_STRING in /in/U2CeE(3) : regexp code on line 1 Fatal error: preg_replace(): Failed evaluating code: 0em in /in/U2CeE on line 3
Process exited with code 255.
Output for 4.3.5 - 4.3.10
Parse error: parse error, unexpected T_STRING in /in/U2CeE(3) : regexp code on line 1 Fatal error: Failed evaluating code: 0em in /in/U2CeE on line 3
Process exited with code 255.
Output for 4.3.4
Parse error: parse error in /in/U2CeE(3) : regexp code on line 1 Fatal error: Failed evaluating code: 0em in /in/U2CeE on line 3
Process exited with code 255.
Output for 4.3.2 - 4.3.3
Parse error: parse error in /in/U2CeE(3) : regexp code on line 1
Process exited with code 139.
Output for 4.3.0 - 4.3.1
Parse error: parse error, unexpected T_STRING in /in/U2CeE(3) : regexp code on line 1
Process exited with code 139.