public static function join($path1, $path2) {
        $ds = DIRECTORY_SEPARATOR;
        return str_replace("$ds$ds", $ds, implode($ds, array_filter(func_get_args())));
    }
public static function join($path1, $path2) {
        $ds = DIRECTORY_SEPARATOR;
        return str_replace("$ds$ds", $ds, implode($ds, array_filter(func_get_args())));
    }
public static function join ( $ path1 , $ path2 ) { $ ds = DIRECTORY_SEPARATOR ; return str_replace ( "$ds$ds" , $ ds , implode ( $ ds , array_filter ( func_get_args ( ) ) ) ) ; }
Joins paths together

@param string $path1
@param string $path2
@param string ...
@return string
Joins paths together