2016-01-21 115 views
0

我在我的網站上有URL,例如http://example.com/test,我需要這個頁面顯示爲子域,例如http://test.example.com/創建頁面作爲子域,而不在服務器上創建子域

我試過以下的東西。

我在htaccess中設置了redirect 301規則,但總是重定向到主頁 。 Redirect 301 /test http://test.example.com/

我幾乎很少使用的WordPress插件wp subdomain revisitedMain category as subdomain,但沒有運氣,所以也許他們是舊版本。

我已經設置了通配符子域(* .subdomain.com),並且該文件夾被設置爲公共html主根目錄。

請幫忙。

+1

的可能的複製[如何讓PHP爲每個用戶自動創建域名?](http://stackoverflow.com/questions/183928/如何讓php-to-create-subdomain-automatically-for-each-user) – Rehmat

回答