3v4l.org

run code in 300+ PHP versions simultaneously
<?php $tests = [ '1:10.10', '1.5.07', '0.3', '00:13,40', '15,17', ]; var_export( preg_replace_callback( '~(?:(\d{1,2})[:.,](?!\d+$))?(?:(\d{1,2})[:.,])?(\d{1,2})$~', function($m) { return sprintf('%02d:%02d.%02d', $m[1], $m[2], $m[3]); }, $tests ) );
Output for git.master, git.master_jit, rfc.property-hooks
array ( 0 => '01:10.10', 1 => '01:05.07', 2 => '00:00.03', 3 => '00:13.40', 4 => '00:15.17', )

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