3v4l.org

run code in 300+ PHP versions simultaneously
<?php function prepareForOutput($content, $exclude=[]) { if (stripos(PHP_OS, 'WIN') === 0) { if (in_array("\r", $exclude, true) === false) { $content = str_replace("\r", '\r', $content); } if (in_array("\n", $exclude, true) === false) { $content = str_replace("\n", '\n', $content); } if (in_array("\t", $exclude, true) === false) { $content = str_replace("\t", '\t', $content); } } else { if (in_array("\r", $exclude, true) === false) { $content = str_replace("\r", "\033[30;1m\\r\033[0m", $content); } if (in_array("\n", $exclude, true) === false) { $content = str_replace("\n", "\033[30;1m\\n\033[0m", $content); } if (in_array("\t", $exclude, true) === false) { $content = str_replace("\t", "\033[30;1m\\t\033[0m", $content); } if (in_array(' ', $exclude, true) === false) { $content = str_replace(' ', "\033[30;1m·\033[0m", $content); } }//end if return $content; } for ($i = 0; $i < 10000; $i++) { prepareForOutput('{echo 1;}', ["\r"]); }
Output for git.master_jit, git.master, rfc.property-hooks

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:
123.39 ms | 405 KiB | 5 Q