Hello qooxdooer’s J

 

I’m starting to use QxRequest and I’ve followed the steps in

http://old.qooxdoo.org/documentation/transport-api-ajax

 

But I get the following error:

 

QxRequest[HASHCODE:252]

009188:Failed to execute "_dispatchEvent()":Could not dispatch event of type "completed":e.getData().getContent is not a function

 

My code is the following:

btLogin.addEventListener('click', function(e) {

                var u_name = txUser.getValue();

                var u_password = txPass.getValue();

                var myTransport = new QxRequest('/user/login', 'POST', 'text/html');

                myTransport.addEventListener('completed', function(e) {

                        alert(e.getData().content);

var msg ="<pre>";

                        for(idx in e.getData().getContent()) {

                                msg += "e[" + idx + "] => " + e[idx] + "<br/>\n";

                        }

                        msg += "</pre>";

                        var wdw = window.open('','wdw');

                        wdw.document.write(msg);

                });

                myTransport.send();

        });

 

The variables txUser and txPass are QxTextFields.  btLogin is a QxButton.

 

What am I doing wrong?

 

Thanks in advance,

 

P.

_______________________________________________
Qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to