Mecha CMS

Path::R()

Remove root directory from file path.

2.2.0 Static

Path::R(string $value, string $root = ROOT, string $join = DS);

Example:

$A = Path::R('.\foo\bar\baz\qux', '.\foo\bar');
$B = Path::R('.\foo\bar\baz\qux', '.\foo', '/');

Result:

$A = 'baz\qux';
$B = 'bar/baz/qux';