On 26 November 2010 10:21, bkrqpzef <bjornulf.frode@gmail.com> wrote: > > Yes i need to use arrays !! > I was able to do want i wanted to do with "array_push". > Thank you again for your precious help, Have a nice day. > > > RQuadling wrote: >> >> On 25 November 2010 16:15, bkrqpzef <bjornulf.frode@gmail.com> wrote: >>> >>> Yeah the key if working. i have forget to put some brackets at the >>> beginning >>> and at the end. I didn't thought that was part of the key. >>> In fact, the code working well with only : >>> >>> $Tarif->TarifParams->Devis->Assure = new AssureInput(); // AssureInput >>> $Tarif->TarifParams->Devis->Assure->Nom        = ''; // string >>> $Tarif->TarifParams->Devis->Assure->Prenom      Â= ''; // string >>> $Tarif->TarifParams->Devis->Assure->NumeroAssure   Â= 2; // int >>> $Tarif->TarifParams->Devis->Assure->Type       Â= 'Adherent'; // >>> string >>> $Tarif->TarifParams->Devis->Assure->DateNaissance   = '19800101'; // >>> string >>> $Tarif->TarifParams->Devis->Assure->RegimeObligatoire = 'SS'; // string >>> >>> But i need to add another Person to this request. >>> like in https://wspar51.april.fr/WSSante/WSSante.asmx?op=Tarif : >>> >>> POST /WSSante/WSSante.asmx HTTP/1.1 >>> Host: wspar51.april.fr >>> Content-Type: text/xml; charset=utf-8 >>> Content-Length: length >>> SOAPAction: "http://www.april-technologies.com/Tarif" >>> >>> <?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:Body> >>>  Â<Tarif xmlns="http://www.april-technologies.com"> >>>   Â<astr_Clef>string</astr_Clef> >>>   Â<TarifParams IdCo="string"> >>>    Â<Devis> >>>     Â<Assure> >>>      Â<Nom>string</Nom> >>>      Â<Prenom>string</Prenom> >>>      Â<NumeroAssure>int</NumeroAssure> >>>      Â<Type>string</Type> >>>      Â<DateNaissance>string</DateNaissance> >>>      Â<RegimeObligatoire>string</RegimeObligatoire> >>>     Â</Assure> >>>     Â<Assure> >>>      Â<Nom>string</Nom> >>>      Â<Prenom>string</Prenom> >>>      Â<NumeroAssure>int</NumeroAssure> >>>      Â<Type>string</Type> >>>      Â<DateNaissance>string</DateNaissance> >>>      Â<RegimeObligatoire>string</RegimeObligatoire> >>>     Â</Assure> >>>     Â<Parametres> >>>      Â<DateEffet>string</DateEffet> >>>      Â<CodePostal>string</CodePostal> >>>      Â<BesoinHospitalisation>string</BesoinHospitalisation> >>>      Â<BesoinFraisMedicaux>string</BesoinFraisMedicaux> >>>      Â<BesoinDentaire>string</BesoinDentaire> >>>      Â<BesoinOptique>string</BesoinOptique> >>>      Â<Produit>string</Produit> >>>      Â<Garanties xsi:nil="true" /> >>>     Â</Parametres> >>>    Â</Devis> >>>   Â</TarifParams> >>>  Â</Tarif> >>> Â</soap:Body> >>> </soap:Envelope> >>> >>> There are two <Assure> but i can't create another one. :( >>> And of course, I have to do both in the same request. >>> >>> I tried with : >>> $Tarif->TarifParams->Devis->Assure2 = new AssureInput(); // AssureInput >>> $Tarif->TarifParams->Devis->Assure2->Nom        = ''; // string >>> $Tarif->TarifParams->Devis->Assure2->Prenom      Â= ''; // string >>> $Tarif->TarifParams->Devis->Assure2->NumeroAssure   Â= 2; // int >>> $Tarif->TarifParams->Devis->Assure2->Type       Â= 'Conjoint'; // >>> string >>> $Tarif->TarifParams->Devis->Assure2->DateNaissance   = '19800102'; // >>> string >>> $Tarif->TarifParams->Devis->Assure2->RegimeObligatoire = 'SS'; // string >>> >>> but it didn't work. >>> -- >>> View this message in context: >>> http://old.nabble.com/-PHP--Soap---Wsdl-Beginner-tp30277723p30306611.html >>> Sent from the Php - Soap mailing list archive at Nabble.com. >>> >>> >>> -- >>> PHP Soap Mailing List (http://www.php.net/) >>> To unsubscribe, visit: http://www.php.net/unsub.php >>> >>> >> >> The issue is the handling of maxOccurs="unbounded" >> >> I'm not 100% on how to handle this on the PHP SoapClient side. >> >> It _MAY_ be you can use ... >> >> $Tarif->TarifParams->Devis->Assure = array(new AssureInput(), new >> AssureInput()); >> >> and then populate $Tarif->TarifParams->Devis->Assure[0] and >> $Tarif->TarifParams->Devis->Assure[1] appropriately. >> >> But I don't know for sure. >> >> >> >> >> -- >> Richard Quadling >> Twitter : EE : Zend >> @RQuadling : e-e.com/M_248814.html : bit.ly/9O8vFY >> >> -- >> PHP Soap Mailing List (http://www.php.net/) >> To unsubscribe, visit: http://www.php.net/unsub.php >> >> >> > > -- > View this message in context: http://old.nabble.com/-PHP--Soap---Wsdl-Beginner-tp30277723p30308912.html > Sent from the Php - Soap mailing list archive at Nabble.com. > > > -- > PHP Soap Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > No problem. I'm glad you got it sorted. And I learned something too. And for the rest of the day, I'm looking into Data Warehousing and OLAP. Lucky me! -- Richard Quadling Twitter : EE : Zend @RQuadling : e-e.com/M_248814.html : bit.ly/9O8vFY -- PHP Soap Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php