logo       

Re: Howto make "nested" arrays?: msg#00047

php.nusoap.general

Subject: Re: Howto make "nested" arrays?

You add another WSDL type

$server->wsdl->addComplexType(
'ArrayOfCoverageReply',
'complexType',
'array',
'',
'SOAP-ENC:Array',
array(),

array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:CoverageReply[]')),
'tns:CoverageReply'
);

That is the type you specify that your method returns.

Scott Nichol

Do not send e-mail directly to this e-mail address,
because it is filtered to accept only mail from
specific mail lists.
----- Original Message -----
From: "Lars Lystrup Christensen" <llc@xxxxxxxxxxxxxxxxx>
To: <nusoap-general@xxxxxxxxxxxxxxxxxxxxx>
Sent: Wednesday, April 13, 2005 2:11 AM
Subject: [Nusoap-general] Howto make "nested" arrays?


Hi there

I've got a SOAP server based on the wonderful nuSOAP and using the WSDL part in
particular.

I want to return an array like this to the client:

Array (
[0] => Array()
[1] => Array()
...
)

The inner part of the array I've already declared with a complextype:

$server->wsdl->addComplexType(
'CoverageReply',
'complexType',
'struct',
'all',
'',
array(
'ServiceID' => array('name' => 'ServiceID', 'type' => 'xsd:string'),
'Coverage' => array('name' => 'Coverage', 'type' => 'xsd:string'),
'Forecast' => array('name' => 'Forecast', 'type' => 'xsd:int')
)
);

But how do I return the outer array in a numbered form? In another way, how do
I return multiple instances of "CoverageReply"...?

______________________________________
Med venlig hilsen / Kind regards

Lars Lystrup Christensen
IP Operations Technician
Danske Telecom A/S
Lautrupsgade 9, 2
2100 København Ø
llc@xxxxxxxxxxxxxxxxx
+45 35 27 50 00 (Office)
+45 35 27 50 50 (Fax)
+45 35 27 50 23 (Direct)
+45 40 60 55 23 (Mobile)

www.dansketelecom.com
This message may contain confidential and/or privileged information. If you are
not the addressee or authorized to receive this for the addressee, you must not
use, copy, disclose or take any action based on this message or any information
herein. If you have received this message in error, please advise the sender
immediately by reply e-mail and delete this message. Thank you for your
cooperation.




-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_ide95&alloc_id396&op=ick
_______________________________________________
Nusoap-general mailing list
Nusoap-general@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/nusoap-general



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_ide95&alloc_id396&op=click


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise