$server = new soap_server();
$server->configureWSDL("hellowwsdl", "urn:hellowwsdl");
$server->wsdl->addComplexType("some_struct", "complexType", "struct", "all", "",
array("row1_name" => array("name" => "row1_name", "type" => "xsd:string"),
"row2_name" => array("name" => "row2_name", "type" => "xsd:string"))
);
$server->wsdl->addComplexType("some_struct_array", "complexType", "array", "", "SOAP-ENC:Array", array(),
array(array("ref" => "SOAP-ENC:arrayType", "wsdl:arrayType" => "tns:some_structl[]")), "tns:some_struct"
);
$server->register("getInfo",
array("username" => "xsd:string", "pass" => "xsd:string"),
array("return" => "tns:some_struct_array")
);
function getInfo($username, $password)
{
return array(
array('row1_name' => 'text1', 'row2_name' => 'text2'),
array('row1_name' => 'text3', 'row2_name' => 'text4')
);
}