3v4l.org

run code in 300+ PHP versions simultaneously
<?php preg_match( "@^(?:http://)?([^/]+)@i", "http://www.php.net/index.htrnl", $matches); $match = $matches[1]; echo $match;

preferences:
34.53 ms | 402 KiB | 5 Q