3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function path_relative_to($path, $rel) { $rel_lent = strlen($rel); if (strncmp($path, $rel, strlen($rel)) == 0) { return substr($path, strlen($rel)); } else { return ""; } } var_dump(basename(""));
Output for 4.3.0 - 7.1.0
string(0) ""