3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = <<<STRING what is "this <? echo str_replace(':'," '', 'cool'); STRING; foreach (array_column(token_get_all($string), 1) as $token) { echo $token, PHP_EOL; }
Output for 7.1.25 - 7.1.33, 7.2.0 - 7.2.33, 7.3.0 - 7.3.31, 7.4.0 - 7.4.32, 8.0.0 - 8.0.12, 8.0.14 - 8.0.30, 8.1.0 - 8.1.33, 8.2.0 - 8.2.29, 8.3.0 - 8.3.26, 8.4.1 - 8.4.13
what is "this <? echo str_replace(':'," '', 'cool');
Output for 7.3.32 - 7.3.33, 7.4.33, 8.0.13
what is "this <? echo str_replace ':' '', 'cool');

preferences:
151.11 ms | 407 KiB | 5 Q