3v4l.org

run code in 300+ PHP versions simultaneously
<?php $re = '/^http:\/\/(.+).local.master.1ff.space\/$/m'; $str = 'http://usa.yorketo.diet.local.master.1ff.space'; preg_match_all($re, $str, $matches, PREG_SET_ORDER, 0); // Print the entire match result echo $matches[0][1] ?? 'NotFound';

preferences:
82.72 ms | 402 KiB | 5 Q