To be specific, when during an Ajax request the component even returns
a page class or page instance, Tapestry builds and returns a Link as
part of the JSON response, the the client-side loads that Link's URL
into the browser address, performing a redirect.

There are two implementations of ComponentEventResultProcessor, one
for @Traditional and one for @Ajax ... just bear that in mind if you
want to read the existing code, or extend the current behavior. They
are both based on a mapped configuration from return type to a
handler.

On Sun, Aug 9, 2009 at 5:34 PM, Thiago H. de Paula
Figueiredo<thiag...@gmail.com> wrote:
> Em Sat, 08 Aug 2009 15:26:45 -0300, Mario Rabe <mario.r...@googlemail.com>
> escreveu:
>
>> Hi,
>
> Hi!
>
>> how can I do a redirect from a XHR-request? Here an example to make clear
>> what I want to do:
>
> If it was a Tapestry-provided event, you could just return a page instance,
> a page class, an URL or a page name in an event handler method.
> Looking at the Form component sources, it uses this callback instance in its
> VALIDATE_FORM event:
>
> ComponentResultProcessorWrapper callback = new
> ComponentResultProcessorWrapper(componentEventResultProcessor);
>
> componentEventResultProcessor comes from an environmental service:
>
> @Environmental
> private ComponentEventResultProcessor componentEventResultProcessor;
>
> Try using the above callback and please post the results. :)
>
> --
> Thiago H. de Paula Figueiredo
> Independent Java consultant, developer, and instructor
> http://www.arsmachina.com.br/thiago
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>



-- 
Howard M. Lewis Ship

Creator of Apache Tapestry
Director of Open Source Technology at Formos

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

Reply via email to