just a guess without ever having used the T4 cancel feature or looked at
the source, but since you changed the type from submit to button, that
could suggest that the function invoked by onclick calls submit() on the
form as well... so your original submit button would trigger a submit as
well as the onclick script.
Wes Bramhall wrote:
I was wondering how other people wrote cancel buttons for their forms.
Before T4, we had made our own CancelableForm component along with a
CancelButton component.
Since T4, we've gotten rid of our CancelableForm, replacing it with the
T4 Form component and specifying the
cancel="ognl:listeners.listenerMethod" attribute. We kept our
CancelButton component, changing it to be:
<input jwcid="@Submit" value="ognl:label" class="cancelButton"
onclick="javascript:this.form.events.cancel();"/>
We recently noticed that in IE, clicking on the cancel button would
seemingly fire off two threads, as the listener would be called twice
and sysouts in ValidatorFactoryImpl were definitely not synchronized.
We changed our CancelButton and it appears to have fixed this issue. The
new component is:
<input jwcid="@Button" label="ognl:label" class="cancelButton"
onclick="javascript:this.form.events.cancel();" />
I was wondering how other people made cancel buttons and if anyone has
an idea why this was necessary.
Thanks
-Wes
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]