views:

144

answers:

0

I'm using the Zend Framework's Soap Server module and I'm looking to return a complex type that looks like the below, but for the life of me, I can't figure out how to do this...

Desired Output

<?xml version="1.0" encoding="UTF-8"?>
   <SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
    xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:tns="http://example.com/webservices"&gt;

   <SOAP-ENV:Body>
     <ns1:methodResponse xmlns:ns1="http://example.com/webservices"&gt;
       <ResultCode xsi:type="xsd:int">0</ResultCode>
       <ResultText xsi:type="xsd:string">Success</ResultText>
       <Users xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="tns:User[2]">
             <User xmlns="" xsi:type="tns:User">
                 <PlayerSrID xsi:type="xsd:int">123</PlayerSrID>
                 <Winnings xsi:type="xsd:float">100</Winnings>
             </User>
             <User xmlns="" xsi:type="tns:User">
                 <PlayerSrID xsi:type="xsd:int">456</PlayerSrID>
                 <Winnings xsi:type="xsd:float">50</Winnings>
             </User>
      </Users>
     </ns1:methodResponse></SOAP-ENV:Body>
   </SOAP-ENV:Envelope>

Any thoughts as to how to accomplish adding the complex type "User" and creating the Array of Complex Type Users consisting of User types?

I can't seem to find any good documentation on this.

THANK YOU SO MUCH IN ADVANCE!!