You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Paul Stanton <pa...@gunnsoft.com.au> on 2008/04/02 08:00:13 UTC

T4 - async - pre-submit client side handler

Hi guys,

I've got a @Form which submits async, and a @Submit. I've also got an 
onclick js event handler which is causing me some grief, but only for IE:

When the submit button is clicked, in Firefox the js is called, and then 
the form submits as per expected. however in IE the js is called but the 
form does not submit.

If I remove the onclick attribute from the @Submit, the form is 
submitted but the crucial js processing has not been executed. I've 
tried using onmousedown instead of onclick and also onsubmit on the 
@Form, none of which help.

It stinks of a dojo bug with ie to me.

Any tips guys?

thanks, p.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: T4 - async - pre-submit client side handler

Posted by Andreas Andreou <an...@gmail.com>.
dojo.event.connectBefore
and make sure you stop the event (if you want to), otherwise the other
connected function will get executed.

On undefined, Paul Stanton <pa...@gunnsoft.com.au> wrote:
> any ideas guys .. it seems dojo can't attach the ajax submit handler if
>  i have an onclick on my button - therefore is there a way to pre-pend a
>  handler after dojo has attached to the form aka registerForm?
>
>  p.
>
>
>
>  Paul Stanton wrote:
>  > Hi guys,
>  >
>  > I've got a @Form which submits async, and a @Submit. I've also got an
>  > onclick js event handler which is causing me some grief, but only for IE:
>  >
>  > When the submit button is clicked, in Firefox the js is called, and
>  > then the form submits as per expected. however in IE the js is called
>  > but the form does not submit.
>  >
>  > If I remove the onclick attribute from the @Submit, the form is
>  > submitted but the crucial js processing has not been executed. I've
>  > tried using onmousedown instead of onclick and also onsubmit on the
>  > @Form, none of which help.
>  >
>  > It stinks of a dojo bug with ie to me.
>  >
>  > Any tips guys?
>  >
>  > thanks, p.
>
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>  For additional commands, e-mail: users-help@tapestry.apache.org
>
>



-- 
Andreas Andreou - andyhot@apache.org - http://blog.andyhot.gr
Tapestry / Tacos developer
Open Source / JEE Consulting

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: T4 - async - pre-submit client side handler

Posted by Paul Stanton <pa...@gunnsoft.com.au>.
any ideas guys .. it seems dojo can't attach the ajax submit handler if 
i have an onclick on my button - therefore is there a way to pre-pend a 
handler after dojo has attached to the form aka registerForm?

p.

Paul Stanton wrote:
> Hi guys,
>
> I've got a @Form which submits async, and a @Submit. I've also got an 
> onclick js event handler which is causing me some grief, but only for IE:
>
> When the submit button is clicked, in Firefox the js is called, and 
> then the form submits as per expected. however in IE the js is called 
> but the form does not submit.
>
> If I remove the onclick attribute from the @Submit, the form is 
> submitted but the crucial js processing has not been executed. I've 
> tried using onmousedown instead of onclick and also onsubmit on the 
> @Form, none of which help.
>
> It stinks of a dojo bug with ie to me.
>
> Any tips guys?
>
> thanks, p.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org