It sounds like the old HTML element (the one to be replaced) is not there
or has a different markup id.

Another possibility is that the old element is in different document, e.g.
when ModalWindow with a Page is used the page's markup is put in an iframe
and any JS contributed by OnDomReadyHeaderItem that tries to find an HTML
element from the main page will fail. In this case you need to use
document.top.getElementById("theId") to be able to find it.

Martin Grigorov
Wicket Training and Consulting

On Tue, Apr 1, 2014 at 2:11 PM, Rakesh A <iamrakes...@rediffmail.com> wrote:

> Hi,
> I am using Wicket v6.12.0, I've couple of Ajax links, clicking on which
> will
> replace a panel [ajax enabled - markup id is generated], and this click
> also
> results a piece of javascript, which will use the markup id of the panel.
> In some cases I see the the javascript fails saying the DOM element doesn't
> exists. When I enable Ajax debug window and see the response, I do see the
> panel with markup id and the javascript is using the same markup id, but
> still script fails to find the DOM element.
> This script is added using OnDomReadyHeaderItem. Can anyone point me how to
> find the cause of it?
> Thanks,
> Rakesh.A
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/DOM-element-not-found-issue-Ajax-response-tp4665201.html
> Sent from the Users forum mailing list archive at Nabble.com.
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to