/** * Combines the paths. * @param string $path1 * @param string $path2 * @return string */ static function Combine($path1, $path2) { $trimChars = '/'; if (PATH_SEPARATOR != $trimChars) { $trimChars .= PATH_SEPARATOR; } $clean1 = System\String::TrimRight($path1, $trimChars); $clean2 = System\String::TrimLeft($path2, $trimChars); return join('/', array($clean1, $clean2)); }