----- Original Message -----
> Greetings,
>
> I'm trying to figure out a way to have each of my vhosts do a 301
> redirect upon receiving a request which contains "www."
>
> Basically we want to drop all of those www subdomains for SEO
> purposes,
> but we are hosting dozens of websites, and would rather not have to

Really? Just dozens?

> put
> in a redirect on every vhost entry.  My thought were that we could do
> this using mod-rewrite and regexp, but not sure.

Anyway... Sure you could use mod_rewrite to complicate your config
even more -- as, with dozens! of vhosts you're afraid of touching them

But even then you'd have to add, at least:

RewriteEngine On
RewriteOptions inherit

to each vhost.

> Any insights?

Now, instead of complicating things, why not take a shot at simplifying
it with mod_macro:
http://www.cri.ensmp.fr/~coelho/mod_macro/

> Thanks.
>
> --
> --asai

i

--
Igor Galić

Tel: +43 (0) 664 886 22 883
Mail: i.ga...@brainsware.org
URL: http://brainsware.org/

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
   "   from the digest: users-digest-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org

Reply via email to