3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $url = 'http://username:password@hostname/path?arg=value#anchor'; echo parse_url($url, PHP_URL_SCHEME | PHP_URL_PATH);
Output for 5.1.2 - 7.1.0
/path
Output for 4.3.0 - 5.1.1
Notice: Use of undefined constant PHP_URL_SCHEME - assumed 'PHP_URL_SCHEME' in /in/AG0CR on line 4 Notice: Use of undefined constant PHP_URL_PATH - assumed 'PHP_URL_PATH' in /in/AG0CR on line 4 Warning: parse_url() expects exactly 1 parameter, 2 given in /in/AG0CR on line 4