);
else
pageContext.forward(userpage.jsp);
%
Please note that nowhere in my jsp code do I use the out object or
send some outputs back to the client. Yet, I am getting this Cannot
forward after response has been committed error. If I comment out the
forward statements then the error disappears
-
From: Michael Lai [mailto:[EMAIL PROTECTED]
Sent: Monday, September 19, 2005 10:17 PM
To: Tomcat Users List
Subject: Cannot forward after response has been committed
I have a jsp page that processes a login. The (simplified) code is
something like this:
%@ page language=java%
%
String
(login.jsp);
else
pageContext.forward(userpage.jsp);
%
Please note that nowhere in my jsp code do I use the out object or
send some outputs back to the client. Yet, I am getting this Cannot
forward after response has been committed error. If I comment out the
forward statements then the error
the response has been committed by outputting the above
\r\n or whatever
-Original Message-
From: Michael Lai [mailto:[EMAIL PROTECTED]
Sent: Monday, September 19, 2005 10:34 PM
To: Tomcat Users List
Subject: Re: Cannot forward after response has been committed
I have an index.jsp page that checks
I put a 'return' statement after every 'forward' statement in all my jsp
pages and now it seems to be working. Thanks for your feedback.
Actually, my linebreak occurs in the % % tags. I think my email
client might have reformatted my output before sending.
[EMAIL PROTECTED] wrote:
You
Users List
Subject: Tomcat 5: What to look for when reciving 'Cannot forward after
response has been committed'
Hi,
While converting from an older Tomcat version I run into the
IllegalStateException that says
Cannot forward after response has been committed
I dont think that I have duplicate
Hi,
While converting from an older Tomcat version I run into the IllegalStateException
that says
Cannot forward after response has been committed
I dont think that I have duplicate forwards so there must be something else to look for
(My guess is PrintWriter outputs, response.addCookie