httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joshua Slive" <>
Subject Re: [users@httpd] ServerAlias and redirecting, please help
Date Wed, 02 May 2007 13:40:53 GMT
On 5/2/07, Dmitry Hazin <> wrote:
> Yes, that was my mistake. Anyway, without that line it didn't work too :(
> It seems that apache doesn't read RewriteRule directive after it had
> read ServerAlias one..

No, that's not true. As I said, if you want to debug mod_rewite you
need to use the RewriteLog. It could also simply be a question of not
putting the directives in the right place. They should be placed
inside the <VirtualHost> where you want them to have an effect.

> What do you mean "the technique of having two <VirtualHost>s"?
> We do have 2 virtualhosts: one for and one for
> Do you suppose putting redirect directive into the one or what?
> And what to do with ServerAlias then?

I mean that at this reference
there are two techniques for canonicalizing urls. You chose to use the
second one rather than the first one, which I find simpler.

To use <VirtualHost>s, you simply setup a separate <VirtualHost>
section (with appropriate ServerName) for each hostname that you wish
to treat differently. The VirtualHost for would contain
nothing other than a ServerName and a Redirect pointing to the
appropriate location on

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message