On Fri, 7 Apr 2000, Drew Taylor wrote:

> Randal,
> 
> Thanks for the tip. So my question is: what is the best solution? I want
> to redirect http://cloudstock.com/ to http://www.cloudstock.com/. 
> Should I take out the permanent in the Redirect directive? Should the
> www entry come first? Do I need to get another IP address? 

i'm just learning about the beautiful magic of the RewriteEngine.  could
this be a good solution for you?  in order to make sure cookies always
work properly on http://mp3.boston.com which is aliased as
http://music.boston.com, we use the following RewriteRule:

    RewriteEngine on
    RewriteCond %{HTTP_HOST}   !^mp3\.boston\.com       [NC]
    RewriteRule ^/(.*)         http://mp3.boston.com/$1 [L,R]

this ensures that every request gets fixed as "mp3.boston.com" no matter
how it comes to us.  i think this is what you want.

see here for more documentation:

http://www.apache.org/docs-1.2/mod/mod_rewrite.html

ky

Reply via email to