I'm writing an ISAPI DLL, using Delphi 10.4.2 and IIS 10.
The configuration, the content, request-response, the debugging, all working fine.
But, I can't read the request 's custom Headers. The test request has come from Postman.
In TWebModule1.WebModule1DefaultHandlerAction
, the request is inherited from Web.Win.IsapiHTTP.TISAPIRequest
.
I'm using the Web.Win.IsapiHTTP.TISAPIRequest.GetFieldByName()
method, as mentioned in the Embarcadero documentation.
I've added <add name="Access-Control-Allow-Origin" value="*" />
to the configuration file on the server side.
I feel that I'm missing something.
For example, this returns with empty content, but from the client-side I sent it, every GetFieldByName returns with an empty string.
TWebModule1.WebModule1DefaultHandlerAction..
begin
Response.statuscode := 200;
response.Content := Request.GetFieldByName('ic_Something');
Handled := true;
end;