Friday 15 May 2015

javascript - $.ajax Server was unable to process request. ---> Root element is missing -


I based Spell based in my Blackberry PhoneGapp app. I am trying to call the Net Web Service and receive the error. " The server was unable to process on the request. ---> Root element is missing " < P> This is my code.

  var SoapMessageInXML = '& lt; Soaps: Envelope Xmlns: xsi = "http://www.w3.org/2001/XMLSchema-instance" xmlns: xsd = "http://www.w3.org/2001/XMLSchema" xmlns: Soap = "http: // schema .xmlsoap.org / soap / envelope / "& gt; '; Subscribe Message INXML + = '& lt; Soaps: Body & gt; '; SoapMessageInXML + = '& lt; Login xmlns = "http://tempuri.org/" & gt; '; SoapMessageInXML + = '& lt; AUserName & gt; 3007800000 & lt; / AUserName & gt; '; SoapMessageInXML + = '& lt; APassword & gt; 27hitec0 & lt; / A password & gt; '; SoapMessageInXML + = '& lt; DeviceID & gt; 2 & lt; / DeviceID & gt; '; SoapMessageInXML + = '& lt; / Login & gt; '; SoapMessageInXML + = '& lt; / Soap: body & gt; '; SoapMessageInXML + = '& lt; / Soap: envelope & gt; '; $ .ajax ({type: 'post', data: soap message inxml, content type: "text / XML", datatype: "text", cache: incorrect, url: 'https://rippleapi.herokuapp.com/xhr_proxy ? Tinyhippos_apikey = ABC and Tinnewop_arrel = http: //50.57.84.5/MobiTicker_mktService/MobileTicker.asmx? Op = login ', success: function (data) {console.log (data);}, error: function (xhr) {console .log (Xhr);}});   

The response is

  & lt ;? Xml version = "1.0" encoding = "UTF-8"? & Gt; & Lt; Soap: Envelope xmlns: Soap = "http://www.w3.org/2003/05/soap-envelope" xmlns: xsi = "http://www.w3.org/2001/XMLSchema-instance" xmlns: XSD = "Http://www.w3.org/2001/XMLSchema" & gt; & Lt; Soaps: Body & gt; & Lt; Soap: defect & gt; & Lt; Soap: Code & gt; & Lt; Soaps: Value & gt; Soap: Receiver & lt; / Soap: Value & gt; & Lt; / Soap: Code & gt; & Lt; Soaps: Reasons & gt; & Lt; Soap: Text xml: lang = "en" & gt; The server was unable to process the request --- & amp; Gt; The original element is unavailable. & Lt; / Soap: text & gt; & Lt; / Soap: reason & gt; & Lt; Soap: Expansion / & gt; & Lt; / Soap: defect & gt; & Lt; / Soap: Body & gt; & Lt; / Soap: Envelope & gt;   

Can anyone help me please? I'm very worried

change all the lines

  SoapMessageInXML = + '...';   

with

  SOMEMASSE INXML + = '...';    

No comments:

Post a Comment