Web forum is in read-only mode. Login as active registered customer for write access
  Forum Search   New Posts New Posts

TWebHTTPRequest

 Post Reply Post Reply
Author
Stokes Michael View Drop Down
New Member
New Member
Avatar

Joined: 11 Oct 2012
Posts: 20
Post Options Post Options   Quote Stokes Michael Quote  Post ReplyReply Direct Link To This Post Topic: TWebHTTPRequest
    Posted: 20 Nov 2019 at 6:24am
I am assuming HTTPRequest.User and HTTPRequest.Password are for basic authentication and have tried setting them but it seems they are ignored.

I can add a header for Basic Authentication manually and it works fine.

So how can I base64 encode the credentials to add into the header?
I cannot find a function to use.

Back to Top
Bruno Fierens View Drop Down
TMS Support
TMS Support
Avatar

Joined: 11 May 2010
Posts: 8601
Post Options Post Options   Quote Bruno Fierens Quote  Post ReplyReply Direct Link To This Post Posted: 20 Nov 2019 at 8:49am
You can use TWebHTTPRequest.Headers to add header info and you can use the function atob() in web.pas to perform base64 encoding.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down