cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bruno Dumon <>
Subject Re: Cocoon Forms v3 onClick
Date Fri, 14 May 2004 18:48:34 GMT
On Fri, 2004-05-14 at 18:36, wrote:
> Hi all,
> I have a FlowScript that uses Cocoon Forms.  I sets the onClick
> function of an Action widget like so:
>   var wid = form.getWidget();
>   wid.submit.onClick = function() {
>   }
> I recently switched from Cocoon Forms v2 to v3 to take advantage of
> the multiple bindings feature.  Suddenly the FlowScript fails on the
> line wid.submit.onClick = function().
> Anybody know what is going on?
> Does  form.getWidget() return something different in v3?

yes, the forms v3 API isn't compatible with v2.

in v3, getWidget() returns the java widget. The javascript form model is
accessible via the property form.model, thus where you previously used
form.getWidget(), now use form.model

Furthermore, onClick has been renamed to onActivate (and may be renamed
to onAction in the future, which would fit better).

Bruno Dumon                   
Outerthought - Open Source, Java & XML Competence Support Center                

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message