RE: [Shale/JSF] Can I redirect/forward in the init() method?

2006-04-19 Thread James Reynolds
That's doing it.  Thank you!
 

-Original Message-
From: Richard Wallace [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, April 19, 2006 3:17 PM
To: Struts Users Mailing List
Subject: Re: [Shale/JSF] Can I redirect/forward in the init() method?

James Reynolds wrote:
> I want to test a value in session, then redirect or forward to a 
> different view based on the result.  I tried using 
> getExternalContext().redirect("/theOtherPage.jsp"); but I received an 
> exception stating that I cannot redirect after the request is
committed.
> What's the proper way to do this?
>
>   
Try using getExternalContext ().dispatch (viewId);  That should forward
to the page you want.

Rich


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [Shale/JSF] Can I redirect/forward in the init() method?

2006-04-19 Thread Richard Wallace

James Reynolds wrote:

I want to test a value in session, then redirect or forward to a
different view based on the result.  I tried using
getExternalContext().redirect("/theOtherPage.jsp"); but I received an
exception stating that I cannot redirect after the request is committed.
What's the proper way to do this?

  
Try using getExternalContext ().dispatch (viewId);  That should forward 
to the page you want.


Rich


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[Shale/JSF] Can I redirect/forward in the init() method?

2006-04-19 Thread James Reynolds

I want to test a value in session, then redirect or forward to a
different view based on the result.  I tried using
getExternalContext().redirect("/theOtherPage.jsp"); but I received an
exception stating that I cannot redirect after the request is committed.
What's the proper way to do this?

Thanks


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]