3v4l.org

run code in 300+ PHP versions simultaneously
<?php $uri = explode(':', "http://eshopmf-be.oskarmobil.cz/porthos/ld.php", 2); $scheme = strtolower($uri[0]); $schemeSpecific = isset($uri[1]) === true ? $uri[1] : ''; var_dump($uri); var_dump($scheme); var_dump($schemeSpecific); $pattern = '~^((//)([^/?#]*))([^?#]*)(\?([^#]*))?(#(.*))?$~'; $status = @preg_match($pattern, $schemeSpecific, $matches); var_dump($matches);

preferences:
49.81 ms | 402 KiB | 5 Q