3v4l.org

run code in 300+ PHP versions simultaneously
<?php print_r(preg_replace('#\bпхп\b#u', '<|$0|>')); echo PCRE_VERSION . PHP_EOL; echo setlocale(LC_ALL, 0); //print_r(preg_last_error());
Output for 8.0.0 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.6
Fatal error: Uncaught ArgumentCountError: preg_replace() expects at least 3 arguments, 2 given in /in/nSp5T:3 Stack trace: #0 /in/nSp5T(3): preg_replace('#\\b\xD0\xBF\xD1\x85\xD0\xBF\\b#u', '<|$0|>') #1 {main} thrown in /in/nSp5T on line 3
Process exited with code 255.
Output for 7.4.12 - 7.4.33
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 10.35 2020-05-09 C
Output for 7.4.6 - 7.4.11
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 10.34 2019-11-21 C
Output for 7.4.0 - 7.4.5
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 10.33 2019-04-16 C
Output for 7.3.0 - 7.3.33
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 10.32 2018-09-10 C
Output for 7.2.0 - 7.2.33
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.41 2017-07-05 C
Output for 5.5.32 - 5.5.38, 5.6.18 - 5.6.38, 7.0.3 - 7.0.33, 7.1.0 - 7.1.25
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.38 2015-11-23 C
Output for 5.4.43 - 5.4.45, 5.5.27 - 5.5.31, 5.6.11 - 5.6.17, 7.0.0 - 7.0.2
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.37 2015-04-28 C
Output for 5.4.41 - 5.4.42, 5.5.25 - 5.5.26, 5.6.9 - 5.6.10
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.36 2014-09-26 C
Output for 5.5.10 - 5.5.24, 5.6.0 - 5.6.8
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.34 2013-12-15 C
Output for 5.3.24 - 5.3.29, 5.4.14 - 5.4.40, 5.5.0 - 5.5.9
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.32 2012-11-30 C
Output for 5.3.19 - 5.3.23, 5.4.9 - 5.4.13
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.31 2012-07-06 C
Output for 5.3.7 - 5.3.18, 5.4.0 - 5.4.8
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.12 2011-01-15 C
Output for 5.3.6
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.11 2010-12-10 C
Output for 5.3.4 - 5.3.5
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.10 2010-06-25 C
Output for 5.3.3
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.02 2010-03-19 C
Output for 5.3.2
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 8.00 2009-10-19 C
Output for 5.3.0 - 5.3.1
Warning: preg_replace() expects at least 3 parameters, 2 given in /in/nSp5T on line 3 7.9 2009-04-11 C
Output for 5.2.14 - 5.2.17
Warning: Wrong parameter count for preg_replace() in /in/nSp5T on line 3 8.02 2010-03-19 C
Output for 5.2.10 - 5.2.13
Warning: Wrong parameter count for preg_replace() in /in/nSp5T on line 3 7.9 2009-04-11 C
Output for 5.2.7 - 5.2.9
Warning: Wrong parameter count for preg_replace() in /in/nSp5T on line 3 7.8 2008-09-05 C
Output for 5.2.6
Warning: Wrong parameter count for preg_replace() in /in/nSp5T on line 3 7.6 2008-01-28 C
Output for 5.2.5
Warning: Wrong parameter count for preg_replace() in /in/nSp5T on line 3 7.3 2007-08-28 C
Output for 5.2.4
Warning: Wrong parameter count for preg_replace() in /in/nSp5T on line 3 7.2 2007-06-19 C
Output for 4.3.10 - 4.3.11, 4.4.0 - 4.4.9, 5.0.2 - 5.0.5, 5.1.1 - 5.1.6, 5.2.0 - 5.2.3
Warning: Wrong parameter count for preg_replace() in /in/nSp5T on line 3 Notice: Use of undefined constant PCRE_VERSION - assumed 'PCRE_VERSION' in /in/nSp5T on line 4 PCRE_VERSION C
Output for 5.1.0
Fatal error: fatal flex scanner internal error--end of buffer missed in /in/nSp5T on line 6
Process exited with code 255.
Output for 4.3.0 - 4.3.9, 5.0.0 - 5.0.1
Warning: Wrong parameter count for preg_replace() in /in/nSp5T on line 3 Notice: Use of undefined constant PCRE_VERSION - assumed 'PCRE_VERSION' in /in/nSp5T on line 4 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/nSp5T on line 4 PCRE_VERSIONPHP_EOLC

preferences:
230.04 ms | 402 KiB | 424 Q