[lug] org net redirect or modrewrite to com

dio2002 at indra.com dio2002 at indra.com
Wed Aug 1 19:34:58 MDT 2007


> On Wed, Aug 01, 2007 at 09:57:58AM -0600, Ted Logan wrote:
>>ServerAlias rule inside your VirtualHost. If you use this rule,
>>http://www.blah.com/random.html, http://www.blah.org/random.html, and
>>http://www.blah.net/random.html all point to the exact same file.
>
> The problem here is that google may then start detecting each as different
> sites, causing links to count towards the page ranks of the different
> sites, etc.  I recommend using a permanent redirect, which google will see
> and treat like a single site.
>
>>        Redirect / http://www.blah.com
>
> I always do:
>
>    Redirect /(.*) http://www.blah.com/$1
>
> so that the same URL on the other virtual sites just redirects to the same
> page on the real site.

Odd, i found that

Redirect / http://www.blah.com

works for me and delivers all pages no matter how far nested off root:

Redirect /(.*) http://www.blah.com/$1

does not.  i'm not sure but i think the aliasing might only be available
to the RedirectMatch Directive and not Redirect (at least in apache 2.0).

also see my other comment about 301 in the other post for better seo.

thanks






More information about the LUG mailing list