wicket-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ernesto Reinaldo Barreiro <reier...@gmail.com>
Subject Re: DOM element not found issue - Ajax response
Date Fri, 04 Apr 2014 06:33:40 GMT

Are you blocking the UI during AJAX requests? I have seen similar weird
things happening because:

1- One AJAX request (R1) is executing.
2- UI is not blocked. User click on on something. A second AJAX (R2)
request is queue: as far as I understand AJAX request are queued by channel
(please, Martin, correct me if I'm telling something wrong).
3- R1 completes and does some DOM replacements.
4- R1 is sent and after server response tries to do something on DOM but R1
already replaced that element.

Try blocking the UI.

On Fri, Apr 4, 2014 at 7:22 AM, Rakesh A <iamrakesh22@rediffmail.com> wrote:

> Hi,
> In my case, the DOM element is not part of iframe/modal window, its in the
> current page itself. And the 'id' attribute used by javascript is also part
> of the same Ajax response. And I am using JQuery to reference this DOM
> element.
> What I am doing is.
> 1. Go to my page
> 2. Press F5 to refresh my wicket page [unversioned], and wait for the page
> to load completely.
> 3. Click on one AjaxLink which replaces another component in the same page.
> Step#3 here responds markup and Javascript [JQuery script], I see that the
> 'id' attribute used by JQuery is part of the same Ajax response. But still
> JQuery fails to find this DOM element.
> There is another case where I get similar issue.
> When my application is deployed over network, and is accessed from a
> different machine [with some network lag]. On the page I've one AjaxLink &
> and Component with Ajax on click behavior added to it.
> 1. Click on component with ajax on click behavior.
> 2. Click on AjaxLink, without waiting for the first request to complete.
> The AjaxLink in both scenarios is the same link, and replaced another
> component.
> Thanks,
> Rakesh.A
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/DOM-element-not-found-issue-Ajax-response-tp4665201p4665258.html
> Sent from the Users forum mailing list archive at Nabble.com.
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org

Regards - Ernesto Reinaldo Barreiro

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message