[Twisted-web] How to insert an Athena event handler using Stan?

Jean-Paul Calderone exarkun at divmod.com
Tue Oct 31 13:56:19 CST 2006

On Tue, 31 Oct 2006 11:57:05 -0500, Phil Christensen <phil at bubblehouse.org> wrote:
> [snip]
>Now I'm just realizing what JP was referring to. That's definitely 
>acceptable syntax, but it still doesn't seem to be working for me.  Using 
>  T.div(render=T.directive('liveElement'))[
>  T.input(type="text", size=80, onKeyUp='Nevow.Athena.Widget.get 
>  ]
>works, but this:
>  T.div(render=T.directive('liveElement'))[
>  T.input(type='text', size=80)[athena.handler(event='onkeypress', 
>  ]
>fails without generating any error. I guess I'm okay with the first  version 
>for my particular use-case, but I'd be interested to know if  there's 
>something obvious I'm missing, or other information I can  supply.

How does it fail?  Can you throw together a minimal self-contained example?
I use this in a lot of places and it works and as far as I understand there
is no reason it shouldn't.


More information about the Twisted-web mailing list