Sample code for 30+ languages & platforms
VBScript

Example: Http.GetUrlPath method

Demonstrates the GetUrlPath method.

Chilkat VBScript Downloads

VBScript
Dim fso, outFile
Set fso = CreateObject("Scripting.FileSystemObject")
'Create a Unicode (utf-16) output text file.
Set outFile = fso.CreateTextFile("output.txt", True, True)

success = 0

set http = CreateObject("Chilkat.Http")
url = "https://example.com/folder/page?lang=en&sort=asc#section2"
outFile.WriteLine(http.GetUrlPath(url))

' Output:

' /folder/page

outFile.Close