2012-07-27 60 views
0

我有一個域,但它沒有在網絡主機上的文件。我想知道是否可以在我的虛擬主機上僅使用.htaccess進行以下操作。用HTACCESS重定向沒有任何索引文件

但我想基本上使用這個是我想重定向我的web根http://(www.)mydomain.nethttp://domain2.net。我想http://(www.)mydomain.com/1/重定向到domain3.net

有人可以幫我嗎?

非常感謝!

回答

0

您可以使用S簡單的301指令與目錄混合做到這一點:

我想指出mydomain1.com到ip xxx.xxx.xxx.xxx/mydomain1,然後在htaccess的在該目錄中:

Redirect 301/http://domain1.net/ 

然後你可以重複相同的站點2:點現場爲ip xxx.xxx.xxx.xxx/mydomain2和htaccess的該目錄

Redirect 301/http://domain2.net/