[plug] redirecting url's

James Devenish devenish at guild.uwa.edu.au
Sat Feb 22 20:52:53 WST 2003


In message <Pine.LNX.4.44.0302222030470.1259-100000 at soulasylum.penguincare.com.au>
on Sat, Feb 22, 2003 at 08:38:43PM +0800, Matt Kemner wrote:
> You can put a redirect on a webpage on your linux box to redirect to a
> page at your ISP, which is as simple as adding the following within the
> <HEAD> ... </HEAD> clause of your homepage:
> 
> <META HTTP-EQUIV=Refresh CONTENT="0; URL=http://www.isp.net.au/~darren/">

Argh! Nooooooooooo! There is no such HTTP header as "Refresh". This sort
of trick causes problems with back buttons, search engines, etc. People
should use 'redirects' instead (response code 302 and a 'Location'
header) -- not a web page with a 0-delay "refresh". With Apache,
you can use the Redirect or RewriteRule directives, for example.

> If you wanted to have the dynamic DNS entry point directly at the ISP's
> webpage, then you will need your ISP's cooperation with that, since they
> will need to add the appropriate details to their webserver config

Also, be aware that it can take time for DNS changes to propagate,
depending on your setup and how recently your address was cached.

And if you want to do a redirect from a webserver on your Linux box to
your ISP's web server, your Linux box (or something else at its address)
will of course have to be contactable and operational.

You could consider an option to have your DNS name always point to your
ISP and have requests proxied from there to your Linux box. This has an
obvious performance penalty, of course, but in the case of your Linux
box becoming uncontactable, you wouldn't have to reconfigure your DNS.





More information about the plug mailing list