Join-Uri¶
SYNOPSIS¶
Join a base URI with a child paths.
SYNTAX¶
Join-Uri [-Path] <Uri> [-ChildPath] <String> [[-AdditionalChildPath] <String[]>]
[-ProgressAction <ActionPreference>] [<CommonParameters>]
DESCRIPTION¶
Join a base URI with a child paths to create a new URI. The child paths are normalized before joining with the base URI.
EXAMPLES¶
EXAMPLE 1¶
Join-Uri -Path 'https://example.com' -ChildPath 'foo' -AdditionalChildPath 'bar'
https://example.com/foo/bar
Joins the base URI https://example.com with the child paths 'foo' and 'bar' to create the URI https://example.com/foo/bar.
EXAMPLE 2¶
Join-Uri 'https://example.com' '/foo/' '/bar/' '//baz/something/' '/test/'
https://example.com/foo/bar/baz/something/test
Combines the base URI https://example.com with the child paths '/foo/', '/bar/', '//baz/something/', and '/test/'.
PARAMETERS¶
-Path¶
The base URI to join with the child path.
Type: Uri
Parameter Sets: (All)
Aliases:
Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-ChildPath¶
The child path to join with the base URI.
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-AdditionalChildPath¶
Additional child paths to join with the base URI.
Type: String[]
Parameter Sets: (All)
Aliases:
Required: False
Position: 3
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-ProgressAction¶
{{ Fill ProgressAction Description }}
Type: ActionPreference
Parameter Sets: (All)
Aliases: proga
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
CommonParameters¶
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.