Hi, Yes I think than when you schedule new request target ajax request target is discarded.
I do not know how this component works but maybe you can return your JSON as part as a javaScript eval target.append("myEvalaJSON('JSON')) ? On Thu, Oct 31, 2013 at 8:35 PM, Nick Pratt <nbpr...@gmail.com> wrote: > Wicket 6.11 > > I have an AbstractDefaultAjaxBehavior that returns JSON in its protected > void respond( AjaxRequestTarget target ) method by: > > requestCycle.scheduleRequestHandlerAfterCurrent( new TextRequestHandler( > "text/plain", "UTF-8", json ) ); > > This ADAB is used for returning status information back to a client side > Javascript component (FileUploader), and the interoperation of the > Javascript component and Wicket via JSON works. > > However, it seems that simple javascript appended to the ART is not being > invoked on the client. Is the scheduleRequestHandlerAfterCurrent() above > replacing the Ajax response that would normally have been sent back to the > client (in this case the Ajax updates - components and javascripts added to > the ART)? > Is there way to return JSON, and also have the ART updates triggered? I'm > not seeing anything in the AjaxDebugger on the client, so it looks like my > simple test alert('here'); is not being sent or interpreted correctly by > the client. > > N > -- Regards - Ernesto Reinaldo Barreiro