www-modproxy-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Graham Leggett <minf...@sharp.fm>
Subject Re: Update: Need help mod_rewrite and mod_proxy :(
Date Wed, 14 Aug 2002 07:18:45 GMT
Lancashire, Pete wrote:

> If the host, inside, the one that is being hidden has
> a href that has a local reference, the proxy seems to
> fail.

The proxy isn't failing, your html is wrong.

> for example I have the file foo.html
> ------------------------------------------------------
> <html><head></head><body>
> This is /foo.html
> click <a href="bar.html">here</a> to go to bar.html
> <br>
> click <a href="http://inside/bar.html">here</a>
> to go to http://inside/bar.html
> <br>
> click <a href="http://inside.domain.xyz/bar.html">here</a>
> to go to http://inside.domain.xyz/bar.html
> </body> </html>
> ------------------------------------------------------
> The first href will get the correct reverse proxy, the
> others will not,  returning the hostname that is in the
> href to the user.


Keep fully qualified website links out of your pages. Proxy does not 
(and cannot) parse your HTML for you. Putting hardcoded URLs in pages 
makes websites difficult to maintain anyway.

As a general rule, relative links (blah.html) will always work, and are 
the most recommended. Absolute links (/dir/blah.html) will only work if 
you keep your URL space the same on the front and the back (which is 
good practice anyway). Hardcoded links (http://inside/dir/blah.html) 
will only ever work on that server, and are unmaintainable whether you 
use a proxy or not.

To my knowledge, MS Proxy server is likely to have the same problem.

	"There's a moon
					over Bourbon Street

View raw message