[Twisted-web] athena widgets and IE

Fabio Forno fabio.forno at gmail.com
Wed Oct 11 05:35:42 CDT 2006

Hi, I've a problem with an athena widget and IE.

I define a widget for a LiveFragment like this one:

var Widgets = {};

Widgets.ChatWidget = Nevow.Athena.Widget.subclass('Widgets.ChatWidget');


    function keyPressed (self, event) {
        if(event.key()["string"] == "KEY_ENTER") {
            text_area = window.document.getElementById("chat_area");
            d = self.callRemote('got_text', text_area.value);

Then in the xml template I try to get a reference to the just defined
method in this way:

widget = Nevow.Athena.Widget.get(


In firefox everything is ok, while in explorer 6.0 I get undefined.
MOreover, in i.e. there is this oddity. if a loop on all the
attributes of widgetwith for(var i in widget) , I get also the
keyPressed method, but when I try to get it with widget[i], I keep
having undefined as result.

Any idea?

Fabio Forno, PhD
Istituto Superiore Mario Boella
Jabber ID: xmpp:ff at kamin.polito.it
** Try Jabber http://www.jabber.org

More information about the Twisted-web mailing list