Be wary of using <redirect/> as the t:saveState tag stops working.
-----Original Message-----
From: Jorge Vásquez [mailto:[EMAIL PROTECTED]
Sent: Sunday, November 26, 2006 2:44 PM
To: 'MyFaces Discussion'
Subject: RE: navigation pages history...
Gerald, can you be a little more detailed in this explanation please?
I'll begin a scenario to help clear out things. I have the following rule
in faces_config.xml:
<navigation-rule>
<navigation-case>
<from-outcome>infoSpaceTool</from-outcome>
<to-view-id>
/pages/tools/infospace/mainInfoSpace.xhtml
</to-view-id>
<redirect/>
</navigation-case>
</navigation-rule>
I have an action method that currently returns "infoSpaceTool" as String and
this causes JSF to load page: /pages/tools/infospace/mainInfoSpace.xhtml.
Now, what would happen when the navigation-case has a redirect element?
Thanks,
JV
-----Mensaje original-----
De: Gerald Müllan [mailto:[EMAIL PROTECTED] Enviado el: domingo, 26 de
noviembre de 2006 14:26
Para: MyFaces Discussion
Asunto: Re: navigation pages history...
Hi,
there is the <redirect>-element in faces-config in order to do such a
forward. You can put it to any navigation rule. Should help in this case.
cheers,
Gerald
On 11/26/06, Jorge Vásquez <[EMAIL PROTECTED]> wrote:
>
>
>
>
> Thanks Julian.
>
> I've Still got one more question:
>
> I am using facelets and in facelets that method returns the name of
> the page, which seems interesting, I need to somehow force a redirect
> to the page returned and stored previously. How can I force a
> redirect to a specific page without using the traditional steps of
> returning an action String and according to that action String and to
> the rules defined in faces_config.xml let the faces Servlet do the
> forward. Again, I want to
do
> an explicit forward from an action method to a specific page, how can
> I accomplish this?
>
>
>
> Regards,
>
> JV
>
>
>
> ________________________________
>
>
> De: Julian Ray [mailto:[EMAIL PROTECTED] Enviado el: sábado, 25
> de noviembre de 2006 5:18
> Para: 'MyFaces Discussion'
> Asunto: RE: navigation pages history...
>
>
>
>
> Its easy to create one. Just use a session scoped bean and add a stack
> to it. You can get the last view rendered using the following
>
>
>
> return FacesContext.getCurrentInstance().getViewRoot().getViewId();
>
>
>
>
>
>
> ________________________________
>
>
> From: Jorge Vásquez [mailto:[EMAIL PROTECTED]
> Sent: Friday, November 24, 2006 9:09 PM
> To: 'MyFaces Discussion'
> Subject: navigation pages history...
>
> Regards,
>
> Is there a way to see the las accessed page that the user was at.
Moreover,
> is there some sort of stack that keeps track of the last accessed
> pages by
a
> specific user inside a JSF application?
>
> Thanks,
>
> JV
>
>
--
http://www.irian.at
Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German
Professional Support for Apache MyFaces