我对服务器端的东西非常陌生。我需要设置一个简单的server.php来接收XML请求。解析XML请求
我甚至不知道如何从这开始。我习惯于从表单中正常的Post/Get变量。
这里是什么,我听的,并需要以回应的例子:
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV: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/"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Body>
<authenticate xmlns="http://someplace.someplace.com/">
<strUserName xsi:type="xsd:string">username</strUserName>
<strPassword xsi:type="xsd:string">password</strPassword>
</authenticate>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
显然有一个用户名/密码,我可以看到里面。
验证用户/密码很容易,但我该如何解析?
http://php.net/manual/en/class.soapserver.php –