Il giorno lun, 28-02-2005 alle 14:17 -0800, Donovan Preston ha scritto:
Another little problem: isn't liveevil.js missing an eval() call on the handler extra arguments?
No; python string literals are now treated as javascript string literals. To produce a javascript string which won't get quoted (and thus will be evaled when it arrives in the browser) you should now use the nevow.livepage.literal string wrapper. The name "literal" will probably change to "js" or something more suitable soon. (Suggestions please?)
So the string won't be evaluated in the context of the nevow_clientToServerEvent() function but directly in the event call, isn't it? So hanlders like: handler(mycallable, "node.value") should now be written: handler(mycallable, liveevil.js("this.value")) substituting "this" to "node"? It is fine for me and even the "js" name is not too bad (i.e., I can't think of anything better right now.) federico -- Federico Di Gregorio http://people.initd.org/fog Debian GNU/Linux Developer fog@debian.org INIT.D Developer fog@initd.org Nessuno dice che non si possa sognare in dettaglio, essere realistici e magari realizzarlo pure, il sogno. -- <dani>