Return-Path: Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Delivered-To: mailing list tomcat-user@jakarta.apache.org Received: (qmail 36991 invoked from network); 4 Aug 2000 16:54:13 -0000 Received: from ha1.rdc1.ct.home.com (HELO mail.rdc1.ct.home.com) (imail@24.2.0.66) by locus.apache.org with SMTP; 4 Aug 2000 16:54:13 -0000 Received: from home.com ([24.2.165.80]) by mail.rdc1.ct.home.com (InterMail vM.4.01.03.00 201-229-121) with ESMTP id <20000804165412.VFN9101.mail.rdc1.ct.home.com@home.com> for ; Fri, 4 Aug 2000 09:54:12 -0700 Sender: web Message-ID: <398AF5FA.E6B3B2C4@home.com> Date: Fri, 04 Aug 2000 12:57:31 -0400 From: Eric Simpson X-Mailer: Mozilla 4.51 [en] (X11; I; Linux 2.2.5-15 i686) X-Accept-Language: en MIME-Version: 1.0 To: tomcat-user@jakarta.apache.org Subject: Re: Tomcat 3.1 + HTTPS + redirects References: <398AE805.A0657B2A@home.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Jason Rumney wrote: > Eric Simpson writes: > > > I'm assuming its redirecting you to the internal web server > > name instead of the external name right? > > > > I got around this by using this redirect code. > > > > response.sendRedirect(request.getScheme() + "://" + reqeust.getServerName() > > + ":" + request.getServerPort()); > > > > and it makes the code a lot more portable also. Hope this > > helps. > > Thanks, > > it seems response.sendRedirect(request.getScheme() + ":" + encoded_url); > is sufficient to take care of my problem (although possibly dependent on > implementation of sendRedirect). I prefer to use relative URLs if > possible rather than try to coerce them into full URLs, and let Tomcat > take care of the path, server name, server port etc. > > -- > Jason Rumney > AT&T Labs (Redditch, UK) jason, I'm not sure what web server your using, but by setting my ServerName directive in apache to my external dns name I'm able to use redirects such as response.sendRedirect("error.html") Eric Simpson