Hi

2014-06-03 10:17 UTC, Dimitrios Chr. Ioannidis <d.ioanni...@nephelae.eu>:
> Hi,
>
>    FYI, in a wst soap client talking to a .net web service i find out,
> that for SOAP calls, if the CONTENT-TYPE http header ( i'm using
> fpc-http-protocol ) doesn't have the 'text/xml' plus the 'charset=UTF-8'
> like this 'text/xml; charset=UTF-8', the server chocks. So, i changed
> the const sSOAP_CONTENT_TYPE in base_soap_formatter.pas to
> sSOAP_CONTENT_TYPE = 'text/xml; charset=UTF-8', and all is working fine.
>
> I don't know if this is a bug or not.

You can change the content using the service reference :

var
  serviceRef : IMyService;
  sp : IServiceProtocol;
begin
   serviceRef := <create the service as in wst_CreateInstance_IMyService() >
   sp := serviceRef as IServiceProtocol;
   
sp.GetSerializer().GetPropertyManager().SetProperty('ContentType','WhatYouWantHere');
   ....
end;


-- 
Inoussa O.
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Reply via email to