如何为xsd:anyType创建soapvar对象

UI *_*per 4 php soap

任何人都可以解释如何在php中使用soapvar为anytype参数指定类型?

  <complexType name="Entry">
            <sequence>
                <element name="key" nillable="true" type="xsd:anyType" minOccurs="0" />
                <element name="value" nillable="true" type="xsd:anyType" minOccurs="0" />
            </sequence>
        </complexType>
Run Code Online (Sandbox Code Playgroud)

例如:

$arr=array('key'=>new SoapVar('EMAIL_ADDRESS',SOAP_ENC_OBJECT,'xsd:anyType'),'value'=>new SoapVar('xxxx@gmail.com',SOAP_ENC_OBJECT,'xsd:anyType'));
Run Code Online (Sandbox Code Playgroud)

当在yodlee sdk中沿soapclient向寄存器用户传递userprofile的上述数组时,它返回"Unknown"异常.

UI *_*per 6

Hai我终于找到了我的问题它基于命名空间url问题,我使用了这个

$arr=array('key'=>new SoapVar('EMAIL_ADDRESS',XSD_ANYTYPE,'string','http://www.w3.org/2001/XMLSchema','key'),'value'=>new SoapVar('xxxx@gmail.com',XSD_ANYTYPE,'string','http://www.w3.org/2001/XMLSchema','value')); 
Run Code Online (Sandbox Code Playgroud)

感谢所有人从yodlee服务器获得解决方案