este es mi xml:
Código HTML:
<wsdl:types> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:ucOrderRequest="http://www.uc.se/schemas/ucOrderRequest/" attributeFormDefault="qualified" elementFormDefault="qualified" targetNamespace="http://www.uc.se/schemas/ucOrderRequest/"> <!-- main (root) elements that are used by the WSDL of the Web Service --> <xsd:element name="businessReport"> <xsd:complexType> <xsd:sequence minOccurs="1"> <xsd:element name="customer" type="ucOrderRequest:customer" minOccurs="1" maxOccurs="1"/> <xsd:element name="repositoryaction" type="ucOrderRequest:repositoryaction" minOccurs="0" maxOccurs="1"/> <xsd:element name="businessReportQuery" type="ucOrderRequest:reportQuery" minOccurs="1" maxOccurs="1"/> </xsd:sequence> <xsd:attribute name="product" type="ucOrderRequest:businessProduct" use="required"/> <xsd:attribute name="version" type="xsd:string" use="required"/> </xsd:complexType> </xsd:element> <xsd:element name="individualReport"> <xsd:complexType> <xsd:sequence minOccurs="1"> <xsd:element name="customer" type="ucOrderRequest:customer" minOccurs="1" maxOccurs="1"/> <xsd:element name="repositoryaction" type="ucOrderRequest:repositoryaction" minOccurs="0" maxOccurs="1"/> <xsd:element name="individualReportQuery" type="ucOrderRequest:reportQuery" minOccurs="1" maxOccurs="1"/> </xsd:sequence> <xsd:attribute name="product" type="ucOrderRequest:individualProduct" use="required"/> <xsd:attribute name="version" type="xsd:string" use="required"/> </xsd:complexType> </xsd:element>
algo asi tendria que verse al parecer...
Código HTML:
<individualReportQuery xmlReplay="true" htmlReplay="false"> <object>4101047373</object> <creditSeeked>24000</creditSeeked> <template id="ABC"> <income type="T" value="248" /> <coObject>4312014431</coObject> <coObjectIncome>198</coObjectIncome> <templateParams> <templateParam id="1" value="J" /> <templateParam id="2" value="1" /> <templateParam id="3" value="430" /> </templateParams> </template> </individualReportQuery>
y este es mi php:
Código PHP:
<?php
$client = new SoapClient(
'https://www.xx.se/UCSoapWeb/services/ucOrders2?WSDL', array(
'location' => 'https://www.xx.se/UCSoapWeb/services/ucOrders2?WSDL',
'userId' => 'xxxxx',
'password' => 'xx',
)
);
$getUserDetails = array(
'customer' => '4101047373',
'individualReportQuery' => ''
);
$param = new SoapParam($getUserDetails, "individualReport");
$functions = $client->__getFunctions();
print_r($functions);
}
try {
$res = $client->individualReport($param);
echo "<pre>"; print_r($res); echo "</pre>";
} catch (SoapFault $exception) {
echo "<pre>"; print_r($exception); echo "</pre>";
exit();
}
?>