found content type of 'text/html; but expected 'text/xml'

K

Kumarforg

Hi,

i get the error
"Client found response content type of 'text/html; charset=utf-8', but
expected
'text/xml'

when i invoke a webservice from a windows client after i enable HttpGet for
the webservice by setting
<add name="HttpGet"/>

in the web.config file.

does it mean that the webservice can't be invoked by win form client using
get request ?

TIA
regards
-Kumarforg
 
J

Jeffrey Hasan

First, I don't recommend making calls with HTTP GET because the protocol is
limited in its ability to represent sophisticated Web service requests. You
can get errors, and I believe this is what is happening to you. The web
service request is failing before it even gets to the Web service, because
it is not correctly formatted. You are probably getting some sort of HTTP
error in return, which is not being mapped back properly. Always use HTTP
POST, don't use HTTP GET. I suspect that HTTP GET is the problem.

Jeffrey Hasan, MCSD
President, Bluestone Partners, Inc.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,012
Latest member
RoxanneDzm

Latest Threads

Top