時間:2015/6/28來源:IT貓撲網(wǎng)作者:網(wǎng)管聯(lián)盟我要評論(0)
剛剛安裝了一個XAMPP 1.8.2,默認(rèn)的訪問80端口是正常的,我配置了一個8000端口,方法就是在httpd.conf文件最后面增加:
<Directory "E:/web">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
# 添加8000端口
Listen 8000
NameVirtualHost *:8000
<VirtualHost *:8000>
ServerName localhost
DocumentRoot "E:\web\myweb"
</VirtualHost>
但是以"localhost:8000"訪問的時候,卻發(fā)現(xiàn)出現(xiàn)了"access forbidden!"的403錯誤,顯示沒有訪問權(quán)限。具體的錯誤信息如下:
Access forbidden!
You don't have permission to access the requested directory. There is either no index document or the directory is read-protected.
If you think this is a server error, please contact the webmaster.
Error 403
想了一下,覺得還是權(quán)限<Directory>權(quán)限配置的問題,在httpd.conf找了一下,終于發(fā)現(xiàn)了問題,xampp默認(rèn)的設(shè)置是這樣的:
#<Directory />
AllowOverride none
Require all denied
</Directory>
修改成下面的就可以了!
<Directory />
Options FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
</Directory>
關(guān)鍵詞標(biāo)簽:XAMPP,403錯誤,解決辦
相關(guān)閱讀
熱門文章 ISAPI Rewrite實現(xiàn)IIS圖片防盜鏈IIS6.0下配置MySQL+PHP5+Zend+phpMyAdmin在Windows服務(wù)器上快速架設(shè)視頻編解碼器全攻win2000server IIS和tomcat5多站點配置
人氣排行 XAMPP配置出現(xiàn)403錯誤“Access forbidden!”的解決辦法WIN2003 IIS6.0+PHP+ASP+MYSQL優(yōu)化配置訪問網(wǎng)站403錯誤 Forbidden解決方法Server Application Unavailable的解決辦法如何從最大用戶并發(fā)數(shù)推算出系統(tǒng)最大用戶數(shù)報錯“HTTP/1.1 400 Bad Request”的處理方法http 500內(nèi)部服務(wù)器錯誤的解決辦法(windows xp + IIS5.0)Windows Server 2003的Web接口