[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Parse error when trying to send a SOAP document with http_url_po st_xml()



I've figured it out. Please don't waste your time.

 

I'm missing a greater than symbol (>) in the body of the SOAP document. I have literally been trying to get this to work for 'days'.

 

 

 

-----Original Message-----
From: owner-ftpapi@xxxxxxxxxxxxx [mailto:owner-ftpapi@xxxxxxxxxxxxx] On Behalf Of Charette, William
Sent: Tuesday, May 02, 2006 12:38 PM
To: 'ftpapi@xxxxxxxxxxxxx'
Subject: Parse error when trying to send a SOAP document with http_url_po st_xml()

 

Hi;

 

I've written a number of successful web services programs using this web site (URL is below) with different web services in the SOAP field.

 

Now, I can't get past error #66 for this page.

I never got this particular web service to work.

I don't know what the error text SetError() #66: XML parse failed at line 2, col 0: no element found" relates to.

 

Below is the error I'm getting using the http_url_post_xml().

(This is the entire debug text.)

I'm not connecting to the web service, so, is the URL referenced below even going out?

(The call to http_url_post_xml() is listed below.)

 

HTTPAPI Ver 1.15 released 2006-03-30    

                             

SetError() #66: XML parse failed at line 2, col 0: no element found  

 

 

I really feel like I'm missing something obvious in the SOAP contents.

Please refer to the highlighted lines within the "<soap:body>" (below).

 

Would the parse error be because the elements have sub-elements?

 

 

Here's the "SOAP" value:

 

SOAP =   

   '<?xml version="1.0" encoding="utf-8"?>'                   

 + '<soap:Envelope'                                           

 + ' xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"'   

 + ' xmlns:xsd="http://www.w3.org/2001/XMLSchema"'             

 + ' xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">' 

 + ' <soap:Header>'                                           

 + '<MultiSpeakMsgHeader Version="3.0"'                       

 + ' UserID="dkeidske" Pwd="dkei3mfik"'                            

 + ' Company="dkdiendike"'                                        

 + ' CSUnits="other"'                                         

 + ' xmlns="http://www.multispeak.org/Version_3.0" />'        

 + '</soap:Header>'                                            

 + '<soap:Body>'                                              

 + '<MeterChangedNotification'                                

                       + ' xmlns="http://www.multispeak.org/Version_3.0">'          

      + '<changedMeters>'                                           

                 + '<meter>'                                                  

                           + '<meterNo>' + %trim(MeterIn) + '</meterNo>'                

                           + '<manufacturer>Austin</manufacturer>'                      

                 + '</meter>'                                                 

      + '</changedMeters>'                                         

 + '</MeterChangedNotification'                               

 + '</soap:Body>'                                             

 

 

 

Or, is it the URL http://demo.turtletech.com/latest/webAPI/MR_CB.asmx :

(I cannot see a typo comparing this URL to those I used.)

 

Here's the call:

rc = http_url_post_xml(                                               

    'http://demo.turtletech.com/latest/webAPI/MR_CB.asmx'              

                   : %addr(SOAP) + 2                                   

                   : %len(SOAP)                                        

                   : *NULL                                             

                   : %paddr(Incoming)                                  

                   : *NULL                                              

                   : HTTP_TIMEOUT                                      

                   : HTTP_USERAGENT                                    

                   : 'text/xml; charset=utf-8'                         

   : 'http://www.multispeak.org/Version_3.0/MeterChangedNotification');