Post in JQuery XML using WCF RRS feed

  • Question

  • I tried testing my WCF with the Visual Studio tool called WCF Test Client. It works perfectly returning an XML structure. When I try doing the same process within Chrome console writing JQuery statement. So I was expecting to get a result saying "Data Insert Success". So Im going to let you see what Ive done so far.

    WCF Test Client:



    <s:Envelope xmlns:s="">
        <Action s:mustUnderstand="1" xmlns=""></Action>
        <ValidarDatosClientes xmlns="">


    <s:Envelope xmlns:s="">
      <s:Header />
        <ValidarDatosClientesResponse xmlns="">
          <ValidarDatosClientesResult>1.0-&gt;Información ingresada exitosamente.</ValidarDatosClientesResult>

    The method for this web service is ValidarDatosClientes(). So this perfectly works.

    What I want is to have a similar response within the Chrome console using JQuery.

    Ive been getting errors like 400/ 400 Bad Request or even "Undefined"

        url: "http://IP(Hidden for security):PORT",
        data: "<campaña>test</campaña>"
        type: 'POST',
        contentType: "text/xml",
        dataType: "text",
        success : parse,
        error : function (xhr, ajaxOptions, thrownError){  

    Im using the console on the same domain. Thank you very much in advance.

    Friday, June 15, 2018 4:40 PM

All replies

  • Hi gangrelg,

    I suggest you try to set "processData: false," in ajax like below:

        url: webServiceURL, 
        type: "POST",
        dataType: "xml", 
        data: soapMessage, 
        processData: false,
        contentType: "text/xml; charset=\"utf-8\"",
        success: OnSuccess, 
        error: OnError

    Best Regards,


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact

    Monday, June 18, 2018 5:40 AM