3v4l.org

run code in 300+ PHP versions simultaneously
<?php $code = "-\r-\r\n-\n-"; $hex = bin2hex($code); var_dump($hex); $code1 = str_replace("\r\n", "\n", $code); $hex = bin2hex($code1); var_dump($hex); $code2 = str_replace(array("\r\n", "\r"), "\n", $code); $hex = bin2hex($code2); var_dump($hex);
Output for git.master, git.master_jit, rfc.property-hooks
string(16) "2d0d2d0d0a2d0a2d" string(14) "2d0d2d0a2d0a2d" string(14) "2d0a2d0a2d0a2d"

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:
49.42 ms | 401 KiB | 8 Q