Why doesn't Response.sendRedirect() work after the binding of Tomcat with Apache server?

Oren Deri

Tomcat communicates with the Apache server using localhost. When tomcat gets the request it's from the Apache on localhost, so it also redirects the response to localhost.

Try the following:

  "http://" + request.getHeader("host") + "/" + yourFileName
About | Sitemap | Contact