The xml response you are receiving is NOT valid xmlrpc: inside a STRUCT 
element, there are supposed to be many MEMBER lements, each one of which has a 
NAME and a VALUE, eg:

STRUCT
  MEMBER
    NAME hello /NAME
    VALUE world /VALUE
  /MEMBER
  MEMBER
    NAME merry /NAME
    VALUE christmas /VALUE
  /MEMBER  
  
in your case a single MEMBER contains multiple NAME/VALUE pairs, and the lib 
only parsers the last one (the 'cs').

Did you build the response xml by hand or using a ready-made library?
If you are using a library, you should ask the maintainers to patch it.
Since I see no PHP mentioned in the http headers of the response, I assume you 
are not using phpxmlrpc on the server side.

Bye
Gaetano

-----Messaggio originale-----
Da:     [EMAIL PROTECTED] per conto di steppel
Inviato:        gio 22/12/2005 18.23
A:      phpxmlrpc@lists.usefulinc.com
Cc:     
Oggetto:        [phpxmlrpc] Problem with xmlrpc
Hi,

i have one problem with php xmlrpc.

So here is what I am sending:

<?xml version="1.0"?>
<methodCall>
<methodName>Search.PlanningOfOneHouse</methodName>
<params>
<param>
<value><struct>
<member><name>WebpartnerCode</name>
<value><string>***</string></value>
</member>
<member><name>WebpartnerPassword</name>
<value><string>***</string></value>
</member>
<member><name>HouseCode</name>
<value><string>***</string></value>
</member>
</struct></value>
</param>
</params>
</methodCall>

The debugger tells tells me that he got:

HTTP/1.1 200 OK
Date: Thu, 22 Dec 2005 17:18:45 GMT
Server: Apache/2.2.0 (Unix) mod_ssl/2.2.0 OpenSSL/0.9.7f PHP/5.1.1
P3P: policyref="http://***/p3p.xml",CP="NOI CURa ADMa DEVa OUR IND UNI
COM NAV"
Connection: close
Transfer-Encoding: chunked
Content-Type: text/xml

<?xml version="1.0" encoding="iso-8859-1"?>
<methodResponse>
 <params>
  <param>
   <value>
    <struct>
    <member>
     <name>period</name>
     <value><string>1w</string></value>
     <name>arrival-date</name>
     <value><string>23-12-2005</string></value>
     <name>arrival-time-from</name>
     <value><string>1600</string></value>
     <name>arrival-time-until</name>
     <value><string>1800</string></value>
     <name>departure-date</name>
     <value><string>30-12-2005</string></value>
     <name>departure-time</name>
     <value><string>1000</string></value>
     <name>booking-on-request</name>
     <value><string>No</string></value>
     <name>rent-price</name>
     <value><string>1512</string></value>
     <name>rent-price-excl-discount</name>
     <value><string>1880</string></value>
     <name>cs</name>
     <value><string>liiJhiAdgEjbcaubbirlcwlZidnklgkl</string></value>
    </member>
    </struct>
   </value>
  </param>
 </params>
</methodResponse>

---END---

So that is okay, but the then the parser give me the following data
back:

HEADER: date: Thu, 22 Dec 2005 17:18:45 GMT
HEADER: server: Apache/2.2.0 (Unix) mod_ssl/2.2.0 OpenSSL/0.9.7f
PHP/5.1.1
HEADER: p3p: policyref="http://***/p3p.xml",CP="NOI CURa ADMa DEVa OUR
IND UNI COM NAV"
HEADER: connection: close
HEADER: transfer-encoding: chunked
HEADER: content-type: text/xml

---PARSED---
object(xmlrpcval)(3) {
  ["me"]=>
  array(1) {
    ["struct"]=>
    array(1) {
      ["cs"]=>
      object(xmlrpcval)(3) {
        ["me"]=>
        array(1) {
          ["string"]=>
          string(32) "icboIIjlqCcddfOcbhdcclkMbkkkhjpn"
        }
        ["mytype"]=>
        int(1)
        ["_php_class"]=>
        NULL
      }
    }
  }
  ["mytype"]=>
  int(3)
  ["_php_class"]=>
  NULL
}

---END---

So what is the Problem?

Sorry my bad English but I hope you understand my Problem.

Greetings from Germany
Steppel

_______________________________________________
phpxmlrpc mailing list
phpxmlrpc@lists.usefulinc.com
http://lists.usefulinc.com/cgi-bin/mailman/listinfo/phpxmlrpc

Reply via email to