Change Content-Type.

Discussion in 'ASP .Net Web Services' started by KaNos, Aug 8, 2006.

  1. KaNos

    KaNos Guest

    Hello,
    When I consume my webservice, it sends a Content-Type :
    application/soap+xml; charset=utf-8. But I want to change it to Content-Type
    : application/xml; charset=utf-8. Is there something to ad or delete in the
    config file ? I don't know how to do that.
    Thanks for response.
     
    KaNos, Aug 8, 2006
    #1
    1. Advertising

  2. KaNos

    Rinku V Guest

    In your client code try something like:

    HttpWebRequest req = (HttpWebRequest)WebRequest.Create(url);
    req.Method = "GET";
    req.ContentType = "application/xml; charset=utf-8";


    "KaNos" wrote:

    > Hello,
    > When I consume my webservice, it sends a Content-Type :
    > application/soap+xml; charset=utf-8. But I want to change it to Content-Type
    > : application/xml; charset=utf-8. Is there something to ad or delete in the
    > config file ? I don't know how to do that.
    > Thanks for response.
    >
    >
    >
     
    Rinku V, Aug 21, 2006
    #2
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. andy
    Replies:
    1
    Views:
    543
    David Banister
    Jul 15, 2003
  2. TheKeith
    Replies:
    20
    Views:
    107,199
    Chris Morris
    Oct 29, 2003
  3. hazz
    Replies:
    6
    Views:
    50,060
    SkyUCHC
    Jun 9, 2010
  4. Stanimir Stamenkov
    Replies:
    2
    Views:
    794
    Stanimir Stamenkov
    Oct 25, 2005
  5. Thomas Armstrong
    Replies:
    2
    Views:
    219
    Ron Bergin
    Nov 12, 2007
Loading...

Share This Page