the URL
https://username:password@www.sampleurl ... /accounts/
works fine in a web browser, but the code
Code: Select all
put "https://username:password@www.sampleurl.com/v1/accounts/" into tUrl
put URL tURL into tResult
answer tResult
Thanks
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Code: Select all
put "https://username:password@www.sampleurl.com/v1/accounts/" into tUrl
put URL tURL into tResult
answer tResult
Code: Select all
put "https://username:password@www.sampleurl.com/v1/accounts/" into tUrl
put url("file:" & tUrl) into tResult
answer tResult
Code: Select all
put base64Encode(username) into username
put base64Encode(password) into apikey
put "Authorization: Basic" && username & ":" & password & cr into tHeader
set the httpHeaders to tHeader
put "https://www.sampleurl.com/v1/accounts/" into tUrl
put url("file:" & tUrl) into tResult
answer tResult