[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Apache2 & mod_rewrite



Marco wrote:

Angelo Bertolli ha scritto:


I think you need to add ServerAlias domain2.com to your second vhost. When Apache first decides which vhost block to use, it doesn't find one for domain2.com so it defaults to the first block.


I would want that when a user write a URL as http://domain1.com the URL comes rewritten in http://www.domain1.com and when a user write a URL as http://domain2.com the URL comes rewritten in http://www.domain2.com.

Could you help me??

Just add this line:
ServerAlias domain2.com

Under this line:
ServerName www.domain2.com

And see if that works.



Reply to: