Hi David,

It works for me if you specify a port. I see the problem if you don't 
specify the port (assume port 80).

My setup has apache serving port 80 but redirecting requests "/servlet/*" 
to Tomcat 4.1.12 using mod_jk. A servlet on Tomcat then redirects via 
"http://hostname/servlet/foo"; which gets back to the browser as 
"http://hostname:0/servlet/foo";... problem goes away if I'm running on a 
non-default port like 8080 but shows up if I use the default port.

john
 
On Thu, 28 Nov 2002, David Brown wrote:

> John Cho writes: 
> 
> > Hello, 
> > 
> > I'm having an issue with Tomcat 4.1.12 and Apache 1.3.x where if I make a 
> > call to response.sendRedirect("http://hostname/servlet/foo";) Apache for 
> > some reason sends a redirect URL to the browser in the form of: 
> > 
> > http://hostname:0/servlet/foo 
> > 
> > Does anyone know what is causing this? And how to fix it? 
> > 
> > I can get around the problem only by using a RequestDispatcher.forward 
> > instead of the redirect but that's not optimal for me as I want the 
> > browser's URL changed. And although the :0 has no effect on IE, Mozilla 
> > doesn't like it at all. 
> > 
> > I apologize in advance if this is a common problem although I've search 
> > the archives and can find only one email that also mentions this problem 
> > and the thread doesn't discuss a resolution. 
> > 
> > Thanks,
> > john 
> > 
> > 
> > --
> > To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> 
> > 
>  
> 
> Hello John, this works for me: 
> response.sendRedirect("http://hostname:8080/servlet/foo";). All servers: 
> smtpd, httpd, ftpd, others and tc listen on predefined ports. look closer at 
> the docs. hope this helps, david. 
> 
> 
> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
> 


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

Reply via email to