【问题标题】:How to remove Access forbidden! Error 403 from xampp 5.6如何删除禁止访问!来自 xampp 5.6 的错误 403
【发布时间】:2017-10-06 02:26:12
【问题描述】:

我已经尝试了所有在线可用的解决方案,例如

Allow from all
Require all granted

我在 httpd-xampp.conf 中添加了上面的行,但没有任何反应。请帮忙!!

【问题讨论】:

  • 这两个指令来自不同的版本,如果你使用的是 2.4,则使用后者,并且只有那个。
  • @ezra-s 是的,你是对的。感谢您的建议

标签: php apache phpmyadmin xampp


【解决方案1】:
Open httpd-vhosts.conf file and in the bottom of the file change it

<VirtualHost *:80>
DocumentRoot “E:/xampp/htdocs/”
ServerName localhost
<Directory E:/xampp/htdocs/>.
Require all granted 
</Directory>
</VirtualHost>



Here E:/xampp is my project workspace, you can change it as per your settings and Second Change is

Now Open httpd-xampp.conf file and in the bottom of the file change it

#
# New XAMPP security concept
#
<LocationMatch “^/(?i:(?:xampp|security|licenses|phpmyadmin|webalizer|server-status|server-info))”>
Order deny,allow
Allow from all
Allow from ::1 127.0.0.0/8
ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var
</LocationMatch>

NOTE : Make sure u  backup files ( httpd-xampp.conf ) and ( httpd-vhosts.conf ) , Both Files are located in Drive:\xampp\apache\conf\extra

【讨论】:

  • 其实我的 httpd-xampp.conf 文件中没有 LocationMatch 标签。
  • 你能搜索一下这个文件吗....在你窗口右上角的搜索框的帮助下
  • D:\xampp\apache\conf\我的 httpd-xampp.conf 文件的额外路径
  • 如果我的 httpd-xampp.conf 中没有 LocationMatch 标签怎么办。正如我告诉你的,我的 conf 文件中没有这个标签。我也在文件中添加了这个标签,但什么也没发生。
  • 那么请提及这个标签
【解决方案2】:

终于找到了答案——:

试试这个“要求全部授予

Alias /phpmyadmin "D:/xampp/phpMyAdmin/"
<Directory "D:/xampp/phpMyAdmin">
    AllowOverride AuthConfig
    Require all granted
    ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var
</Directory>

【讨论】:

    猜你喜欢
    • 2017-01-04
    • 2013-01-19
    • 2015-05-14
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-05-01
    • 2017-05-07
    • 2012-02-24
    相关资源
    最近更新 更多