0
我已經在Mountain Lion中安裝了XAMPP,並且正試圖將mysite.local別名替換爲localhost /〜user/mysite。本地主機別名無法在XAMPP上工作
在/etc/apache2/extra/httpd-vhosts.conf我:
<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot "/Users/user/Sites/mysite"
ServerName mysite.local
ErrorLog "/private/var/log/apache2/dummy-host2.example.com-error_log"
CustomLog "/private/var/log/apache2/dummy-host2.example.com-access_log" common
</VirtualHost>
,並在/ etc/hosts中我有:
127.0.0.1 localhost mysite.local
當我去http://mysite.local它只顯示我的XAMPP開始頁面。
怎麼辦?
沒有喜悅。我取消了「Include/private/etc/apache2/extra/httpd-vhosts.conf」的註釋並嘗試了'Include/etc/apache2/extra/httpd-vhosts.conf',但我仍然在獲取XAMPP啓動頁面。 – 2013-04-11 06:22:23
聽起來像是你可能正在編輯錯誤的httpd.conf文件,XAMPP使用它自己的東西,通常在/ Applications/XAMPP/etc /(從內存中找到) – Toby 2013-04-11 08:25:24
Sorted,謝謝Toby。 – 2013-04-11 12:39:39