Pagekit\Info\InfoHelper::getRelativePath PHP Method

getRelativePath() protected method

Returns the path relative to the root.
protected getRelativePath ( string $path ) : string
$path string
return string
    protected function getRelativePath($path)
    {
        if (0 === strpos($path, App::path())) {
            $path = ltrim(str_replace('\\', '/', substr($path, strlen(App::path()))), '/');
        }
        return $path;
    }