As an aside,

You could use mod_rewrite to rewrite all requests for page.jsp to 
https:/yourhost/page.jsp

This is assuming that your LoadModule line for mod_rewrite comes before 
mod_jk in httpd.conf.

But maybe this is just confusing the issue.

rls





Frédéric LE MAISTRE <[EMAIL PROTECTED]>
10/23/2002 06:36 AM
Please respond to "Tomcat Users List"

 
        To:     "Tomcat Users List" <[EMAIL PROTECTED]>
        cc: 
        Subject:        Re: relative URL Link question

thanks for your comment
----- Original Message -----
From: "Turner, John" <[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <[EMAIL PROTECTED]>
Sent: Wednesday, October 23, 2002 3:32 PM
Subject: RE: relative URL Link question



If you want to go from unsecure to secure, using a URL on a web page, you
need to make it the full URL.  Otherwise, the browser will rewrite the URL
as a normal HTTP URL.

For example, if you have "page.jsp" on your page, a browser will make this
"http://yourhost/page.jsp"; when rendering the page.  There is no way that I
know of to cause the browser to use "https" instead.

If you want page1.jsp to have a SSL link to page2.jsp, you need to write
that link as "https://yourhost/page2.jsp";.

Incidentally, just changing the port will get you nowhere....you will not
get a SSL connection if you use "http://yourhost:443/page.jsp"; even though
443 is the default SSL port.  Your browser does not key off of port 
number,
it keys off of connection type: http vs. https.  That's why you can run 
SSL
on 8443 for Tomcat stand-alone.  Using "http://yourhost:8443/page.jsp"; will
not result in an SSL connection, but "https://yourhost:8443/page.jsp"; will.

Your page URLs should always be relative, unless they are SSL.  Even then,
you only need the initial URL to be "https://yourhost/page.jsp";. After that,
relative URLs like "page.jsp" will be translated to "https" by the browser
instead of "http".

So, there shouldn't be "localhost" in any of your pages, unless it is the
link transitioning from non-SSL to SSL.  Once you start an SSL session, 
you
should stay with the SSL session, don't flip back and forth.

HTH

John

> -----Original Message-----
> From: Frédéric LE MAISTRE [mailto:be.info@;lafon.fr]
> Sent: Wednesday, October 23, 2002 9:11 AM
> To: Tomcat Users List
> Subject: relative URL Link question
>
>
> Is it possible to make a link to an URL without writing
> http://www.domain.com/page
> but only /page and change the port.
>
> Example : you're on http://www.machin:8080
> and you want to go to the page http://www.machin:443/page.htm
> by clicking on
> a link.
>
> Can this link be only /page (with some information for the port)
>
> I ask this because i'm currently using localhost, but in the
> future it will
> change and i don't want to modify all the links.
>
> Thanks
>
>
> Fred
>
>
> --
> To unsubscribe, e-mail:
> <mailto:tomcat-user-unsubscribe@;jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:tomcat-user-help@;jakarta.apache.org>
>

--
To unsubscribe, e-mail:
<mailto:tomcat-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail:
<mailto:tomcat-user-help@;jakarta.apache.org>



--
To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@;jakarta.apache.org>





--
To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@;jakarta.apache.org>

Reply via email to