CFHTTP content-type doubling on call to ASP.NET
I've been struggling with an ASP.NET web service (they use a later standard than the AXIS installation in CFMX8), so I've been trying to post to the service using CFHTTP.
Here's a sample of the code I'm using:
<cfhttp url="http://URL/template.svc?wsdl" method="POST" resolveurl="NO" useragent="Axis/1.1">
<cfhttpparam type="header" name="Content-Type" value="text/xml; charset=utf-8" />
<cfhttpparam type="header" name="accept-encoding" value="no-compression" />
<cfhttpparam type="header" name="SOAPAction" value="method">
<cfhttpparam type="xml" name="body" value="#soapXML#">
</cfhttp>
The problem is that ASP.NET is returning this error:
Cannot process the message because the content type 'text/xml; charset=utf-8,text/xml; charset=UTF-8' was not the expected type 'text/xml; charset=utf-8'.
If I remove the Content-Type setting, I get:
Unable to determine MIME type of file.
And if I leave the Content-Type empty, I get:
Cannot process the message because the content type ',text/xml; charset=UTF-8' was not the expected type 'text/xml; charset=utf-8'.
So, the question is, how do I tell CFMX8 that I want to control the Content-Type header, and don't want it to send anything at all?
Or, how can I get it to decide that the Content-Type is what I'm sending if I make the header blank, but to send it without the comma?
This is highly frustrating.
On another note, the thread about the web service call is coming soon...
