Hello,
i just started a few days ago with qooxdoo (0.7.2) and i really enjoy to
work with this framework, but now i get stuck in some problem. (Maybe my
question is stupid i don´t know)
I try to make an request using method POST to an AXIS2 based Webservice
(SOAP). I use an XML for posting it to the service and then i try to parse
the conent of the answer.
This is my code example:
function buttonExecute(){
var reqSave = new
qx.io.remote.Request("http://servername/ip_detect/services/Adminservice","PO
ST","application/xml");
var xmldoc = "";
xmldoc +='<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://detect.service.ipsyscon/xsd"
xmlns:xsd1="http://proxool.connect.ipsyscon/xsd">';
xmldoc +='<soapenv:Header/>';
xmldoc +='<soapenv:Body>';
xmldoc +='<xsd:addDatabaseConnect>';
xmldoc +='<xsd:inConnect>';
xmldoc +='<xsd1:alias>abcde</xsd1:alias>';
xmldoc
+='<xsd1:driverClass>com.microsoft.sqlserver.jdbc.SQLServerDriver</xsd1:driv
erClass>';
xmldoc
+='<xsd1:driverUrl>jdbc:sqlserver://servername:2223;DatabaseName=database</x
sd1:driverUrl>';
xmldoc +='<xsd1:maxConnects>10</xsd1:maxConnects>';
xmldoc +='<xsd1:properties>';
xmldoc +='<xsd1:encrypt>false</xsd1:encrypt>';
xmldoc +='<xsd1:name>user</xsd1:name>';
xmldoc +='<xsd1:value>username</xsd1:value>';
xmldoc +='</xsd1:properties>';
xmldoc +='<xsd1:properties>';
xmldoc +='<xsd1:encrypt>false</xsd1:encrypt>';
xmldoc +='<xsd1:name>password</xsd1:name>';
xmldoc +='<xsd1:value>passwort</xsd1:value>';
xmldoc +='</xsd1:properties>';
xmldoc +='<xsd1:validationQuery>select
getdate()</xsd1:validationQuery>';
xmldoc +='</xsd:inConnect>';
xmldoc +='</xsd:addDatabaseConnect>';
xmldoc +='</soapenv:Body>';
xmldoc +='</soapenv:Envelope>';
var xmm = qx.xml.Document.fromString(xmldoc);
reqSave.setFormField("wsdl",xmm);
reqSave.addEventListener("completed", function(e) {
var cont = e.getContent();
zustand.setLabel("completed");
var knot = "return";
if(qx.xml.Document.isDocument(cont))
{
var a =
qx.xml.Element.getElementsByTagNameNS(cont,"http://detect.service.ipsyscon/x
sd",knot);
}
But a is in this case always null or . I tried it also with all the
other static methods from Class qx.xml.Element but i guess i get
something wrong...
The Answer from the webservie should be:
<soapenv:Envelope xmlns:soapenv="
<http://schemas.xmlsoap.org/soap/envelope/>
http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<ns:addDatabaseConnectResponse xmlns:ns="
<http://detect.service.ipsyscon/xsd> http://detect.service.ipsyscon/xsd">
<ns:return>1</ns:return>
</ns:addDatabaseConnectResponse>
</soapenv:Body>
</soapenv:Envelope>
Has anyone more experience with this or a little hint for me? Perhaps it
isn´t a good idea to use qooxdoo objects to do this job?
Thankfull
Nico
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel