You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Bertrand Guay-Paquet <be...@step.polymtl.ca> on 2011/05/03 16:52:28 UTC

Ajax DataTable navigation links

Hello,

I am using an AjaxFallbackDefaultDataTable and getting the 
AccessDeniedPage when clicking too fast on navigation links. This 
happens for example when the displayed page is the second to last and 2 
clicks are quickly made on the "forward"navigation link before the Ajax 
response is received.

The first click is handled correctly: it updates the contents and 
disables the "forward" link.
The second click tries to access a now-disabled link and redirects to 
the AccessDeniedPage.

This does not happen with the DefaultDataTable (non-ajax) because all 
links are relative to the current page id.

Am I missing some configuration? Is this a problem common to all ajax 
links which disable themselves after a click?

Regards,
Bertrand

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


Re: Ajax DataTable navigation links

Posted by Bertrand Guay-Paquet <be...@step.polymtl.ca>.
I ended up implementing the solution proposed here :
http://wicketinaction.com/2008/12/preventing-double-ajax-requests-in-3-lines-of-code/

It's an all or nothing solution, but it works.

On 03/05/2011 10:52 AM, Bertrand Guay-Paquet wrote:
> Hello,
>
> I am using an AjaxFallbackDefaultDataTable and getting the 
> AccessDeniedPage when clicking too fast on navigation links. This 
> happens for example when the displayed page is the second to last and 
> 2 clicks are quickly made on the "forward"navigation link before the 
> Ajax response is received.
>
> The first click is handled correctly: it updates the contents and 
> disables the "forward" link.
> The second click tries to access a now-disabled link and redirects to 
> the AccessDeniedPage.
>
> This does not happen with the DefaultDataTable (non-ajax) because all 
> links are relative to the current page id.
>
> Am I missing some configuration? Is this a problem common to all ajax 
> links which disable themselves after a click?
>
> Regards,
> Bertrand
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>

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