public function relPath($from,$to) {
		$expFrom = explode('/',$from);
		$expTo = explode('/',$to);
		$max=max(count($expFrom),count($expTo));
		$rel = [];
		$base=TRUE;
		for ($i=0;$i<$max;$i++) {
			if ($base && isset($expTo[$i]) && isset($expFrom[$i])
				&& $expTo[$i] === $expFrom[$i])
				continue;
			else
				$base=FALSE;
			if (!empty($expFrom[$i]))
				array_unshift($rel,'..');
			if (!empty($expTo[$i]))
				array_push($rel,$expTo[$i]);
		}
		return implode('/',$rel);
	}
public function relPath($from,$to) {
		$expFrom = explode('/',$from);
		$expTo = explode('/',$to);
		$max=max(count($expFrom),count($expTo));
		$rel = [];
		$base=TRUE;
		for ($i=0;$i<$max;$i++) {
			if ($base && isset($expTo[$i]) && isset($expFrom[$i])
				&& $expTo[$i] === $expFrom[$i])
				continue;
			else
				$base=FALSE;
			if (!empty($expFrom[$i]))
				array_unshift($rel,'..');
			if (!empty($expTo[$i]))
				array_push($rel,$expTo[$i]);
		}
		return implode('/',$rel);
	}
public function relPath ( $ from , $ to ) { $ expFrom = explode ( '/' , $ from ) ; $ expTo = explode ( '/' , $ to ) ; $ max = max ( count ( $ expFrom ) , count ( $ expTo ) ) ; $ rel = [ ] ; $ base = TRUE ; for ( $ i = 0 ; $ i < $ max ; $ i ++ ) { if ( $ base && isset ( $ expTo [ $ i ] ) && isset ( $ expFrom [ $ i ] ) && $ expTo [ $ i ] === $ expFrom [ $ i ] ) continue ; else $ base = FALSE ; if ( ! empty ( $ expFrom [ $ i ] ) ) array_unshift ( $ rel , '..' ) ; if ( ! empty ( $ expTo [ $ i ] ) ) array_push ( $ rel , $ expTo [ $ i ] ) ; } return implode ( '/' , $ rel ) ; }
assemble relative path to go from A to B
@param $from
@param $to
@return string
assemble relative path to go from A to B