2011-06-28 38 views
0

我一直試圖通過macports升級到最新的PHP後整天搞清楚這一點。雖然現在我有一個奇怪的問題,如果我訪問 http://localhost - 這工作正確的在我的網站/用戶/ FOO顯示的網站列表/站點 http://127.0.0.1 - 這顯示默認「它工作的」127.0.0.1和localhost與macports安裝的雪豹不同

我havw我已經創建了一個虛擬主機文件具有以下

<VirtualHost *> 
    DocumentRoot "/Users/foo/Sites" 
    ServerName localhost 
    ServerAlias 127.0.0.1 
    ServerAdmin [email protected] 
    <Directory /> 
     Options FollowSymLinks 
     AllowOverride None 
    </Directory> 
    <Directory /Users/foo/Sites> 
     Options Indexes FollowSymLinks MultiViews 
     AllowOverride All 
     Order allow,deny 
     allow from all 
    </Directory> 
    ErrorLog /opt/local/apache2/logs/error.log 
    # Possible values include: debug, info, notice, warn, error, crit, 
    # alert, emerg. 
    LogLevel warn 
    CustomLog /opt/local/apache2/logs/access.log combined 
</VirtualHost> 

<VirtualHost *:80> 
    ServerAdmin [email protected] 
    DocumentRoot "/Users/foo/Sites/snow" 
    ServerName snow.local 
    ServerAlias www.snow.local 
    ErrorLog "/opt/local/apache2/logs/snow-error_log" 
    CustomLog "/opt/local/apache2/logs/snow-access_log" common 
</VirtualHost> 

我的主機文件包含

127.0.0.1 localhost 
255.255.255.255 broadcasthost 
::1   localhost 
fe80::1%lo0 localhost 
127.0.0.1 snow.local 

回答

0

找到了問題的答案。這是由於打開了「Web共享」設置。