1

I am working in site www.example1.com which is hosted in WAMP server, there is another site which is www.example2.com,when a user type www.example2.com in his browser,it should be redirected to www.example1.com/some-page.

VH .conf file for the www

<VirtualHost *>
 ServerName www.example2.com
 Redirect 301 / http://example1.com/some-page
</VirtualHost>

Currently when a user types example2.com in browser it redirects to something like http://example1.com/some-page/some-page/some-page/some-page/some-page/some-page/some-page/some-page

So, what is the mistake in conf file?

  • Are there any redirects in the config for www.example2.com? – Jenny D Oct 15 '15 at 09:07
  • Or is the VirtualHost entry for example1.com missing? That could make the www.example2.com entry the default VirtualHost and then the redirect points to itself. – HBruijn Oct 15 '15 at 09:11
  • example1.com is default site. So no virtual host entry for this.
    <VirtualHost *> ServerName www.example2.com Redirect 301 / http://example1.com/some-page is only entry in config for example2.com
    – Hiranya Sarma Oct 15 '15 at 09:23

0 Answers0