You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by José Miguel Vieira <mi...@bookmarc.pt> on 2001/10/16 17:12:45 UTC

wsdl

Hello,

I created a web service and I'm trying to execute it in Internet Explorer 
like this:
  http://myserver/sib/EmployeeService.jws?method=getEmployeeByLogin&arg0=james

IE replies:
   "Only one top level element is allowed in an XML document. Line 3, 
Position 2 "

The source of the message was:
<p>Got response message:</p>
<?xml version="1.0" encoding="UTF-8"?>
<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">
  <SOAP-ENV:Body>
   <getEmployeeByLoginResponse>
    <getEmployeeByLoginResult xsi:type="xsd:string">ID: 3 NAME: James 
Globus EMAIL: james@nowhere.com LOGIN: james
PASSWORD: * SECURITY LEVEL: 1 BUGS: PROJECTS:
</getEmployeeByLoginResult>
   </getEmployeeByLoginResponse>
  </SOAP-ENV:Body>
</SOAP-ENV:Envelope>

I think the problem is related with the "<p>Got response message:</p>", 
because the first instruction in a xml message should be
"<?xml version="1.0" encoding="UTF-8"?>".

My question is if this interferes with client access to the services, when 
the clients are not java based and how can I avoid this?

José Miguel Vieira