This is a little complicated to explain, so please bear with me.
Short list of steps of what is happening:
1) On the main page (a .jsp), click the login button which launches a new browser window with the login pages
2) Type in information and submit
3) The page reloads, checks the authentication info (via a javabean), and if successful, uses a response.sendRedirect() to forward it to a close page
4) The close page uses javascript to send the main window to a new page and close itself
Here's where the problem comes in. When the new page loads in the main window, I end up with the entire body of the login page, plus the text at the end of this message, plus the page it is supposed to be displaying. All in one. It seems like on the redirect it is sending all of the html to the buffer, even though I redirected before the html, and then the next page you go to it is writing it all to the screen.
First thought whenever the buffer comes up is "flush the buffer!" But I don't want to send that information at all...that's why I have a redirect. As a side note, I did try to flush the buffer, and it acted just the same. Here's the text that is inserted after the body of the login page and before the body of the page it is redirecting to:
HTTP/1.1 200 OK Date: Wed, 12 Dec 2001 21:25:29 GMT Server: Apache/1.3.12 OpenSSL/0.9.6a (Unix) ApacheJServ/1.1 mod_jk Servlet-Engine:
Tomcat Web Server/3.2.3 (
JSP 1.1;
Servlet 2.2;
Java 1.3.1_01; SunOS 5.6 sparc; java.vendor=Sun Microsystems Inc.) Keep-Alive: timeout=5, max=14 Connection: Keep-Alive Transfer-Encoding: chunked Content-Type: text/html;charset=ISO-8859-1 ffb
Also I should note that if you refresh the page it comes up correctly. Some other links on the site will sometimes (apparently at random) display the wrong page or parts of other pages. Again, a refresh always fixes them.
HELP!