views:

26

answers:

1

Hi, i have created a simple web service using Php Nusoap. its working correctly but the only thing missing is to add the default xmlns attribute to the response tag.

Here is the copy of Response :

<?xml version="1.0" encoding="ISO-8859-1"?>
<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/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/"&gt;
  <SOAP-ENV:Body>
    <LoginResponse xmlns="">
      <LoginResult>
        <register>
          <customer>d2ff3b88d34705e01d150c21fa7bde07</customer>
        </register>
      </LoginResult>
    </LoginResponse>
  </SOAP-ENV:Body>
</SOAP-ENV:Envelope>

How can i add namespace to the LoginResponse tag. Thanx in advance.

A: 

Does adding it to register() work?

  $server->register(
     $methodname,
     $inputparameters,
     $outputparameters,
     $namespace,//<================    
     $soapaction,
     $style,
     $use
  );
Wrikken
No it doesn't work, i have tried it. What are the ways to add attribute to response tag using nusoap.
Rajat
How do you add your complextypes (only worked with 'out-of-the-box'-server, not nusoap).
Wrikken