wood burning stoves 2.0*
The moose likes JSF and the fly likes Redirecting to another page in Bean Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Redirecting to another page in Bean" Watch "Redirecting to another page in Bean" New topic

Redirecting to another page in Bean

Eugene Abarquez
Ranch Hand

Joined: May 18, 2006
Posts: 211

I wanted to do a redirect to another page in my bean. How do you do that in JSF? In JSP, I know it's something like this:

Some sample code will greatly help. Thanks in adcance.

There's so much to learn in this industry, and not everybody has the necessary interest.
Richard Green
Ranch Hand

Joined: Aug 25, 2005
Posts: 536
setup a new navigation rule?

MCSD, SCJP, SCWCD, SCBCD, SCJD (in progress - URLybird 1.2.1)
Brian Smith
Ranch Hand

Joined: May 20, 2005
Posts: 63
Just to elaborate a little more, Navigation in JSF is handled by navigation rules that are defined in faces-config.xml.

They look something like this.

outcome1 and outcome2 are Strings that are returned by a method that your commandButton, commandLink, etc (whatever causes a form submit) on your page are bound to via an action argument. If neither of the <from-outcome> conditions are met, the original page is redisplayed.

[ October 04, 2006: Message edited by: Brian Smith ]
Eugene Abarquez
Ranch Hand

Joined: May 18, 2006
Posts: 211
Thanks guys. But I was actually looking for something like this:

I found it in older posts.
I agree. Here's the link: http://aspose.com/file-tools
subject: Redirecting to another page in Bean
Similar Threads
Not retrieving from the Java Bean
Newbie -- Passing bean information while redirecting
Passing user defined objects as request parameter in JSF
JSF Edit Page
How do i get the value of a TextField component from another page?