PHP - Konvertierung von XML zu array in PHP - Analyse einer soap-xml in php und Speicherung in Datenbank

Möchte ich umwandeln einer soap-xml-Antwort und speichern Sie in einer Datenbank. Hier ist die XML, die ich habe.

<ENV:Envelope xmlns:ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://example.com/soap/example">
   <ENV:Body>
      <ns1:GetCentresResponse>
         <ExampleCentre>
            <ns1:Cent>
               <ID>200</ID>
               <Name>example2</Name>
               <Code>ex2</Code>
               <Email>[email protected]</Email>
               <Address1>example2, example2 </Address1>
               <Address2>example2, example2 </Address2>
               <City>example2</City>
               <PostCode>111111</PostCode>
               <Telephone>1111111111</Telephone>
               <Location>11.11,-11.11</Location>
               <URL>/example2/exam2/ex2</URL>
            </ns1:Cent>
         </ExampleCentre>
      </ns1:GetCentresResponse>
   </ENV:Body>
</ENV:Envelope>

Bekomme ich diese soap-Antwort vom server. Ich will wandeln diese in ein array und speichern es in der Datenbank. Was soll ich tun? Ich weiß, die Antwort könnte ziemlich straight forward, aber hey, bin ein Neuling 😀

Würde wirklich zu schätzen jede Hilfe, die ich bekomme.

Vielen Dank in Vorfreude.

Hinsichtlich

InformationsquelleAutor BasicGem | 2011-09-22

Schreibe einen Kommentar