PHP从SIRI API解析复杂的SOAP响应

I am trying to parse this complex SOAP response: enter image description here

But I get lost with the namespaces and children methods...any idea how to extract the highlighted data?

I tried this:

$xml->children( $ns['S'] )->Body->children( $ns['ns7'] )->Answer->children( $ns['ns3'] );

but it doesn't work

You should use a WSDL to PHP generator which will ease you the request construction and response handling. Indeed, you'll handle PHP object with getters/setters which is better in my point of view.

I can only suggest you to try the PackageGenerator project.