PHP错误:Forbidden You don't have permission to access / on this server.-阿里云开发者社区

开发者社区> 杰克.陈> 正文

PHP错误:Forbidden You don't have permission to access / on this server.

简介: 原文:PHP错误:Forbidden You don't have permission to access / on this server. 今天老大让在xp下搭建一个FTP服务器,一波三折,最后终于在老大的帮助下搞定了。
+关注继续查看
原文:PHP错误:Forbidden You don't have permission to access / on this server.

今天老大让在xp下搭建一个FTP服务器,一波三折,最后终于在老大的帮助下搞定了。。。

其中通过ip访问的时候 提示 Forbidden You don't have permission to access / on this server.

找到一个解决方法,特此记录

 

php的配置文件httpd.conf。

在原有的位置文件中找到配置节

<Directory />
    Options FollowSymLinks
    AllowOverride None
    Order deny,allow
    Deny from all
    Satisfy all
</Directory>

 

修改成

<Directory />
    Options FollowSymLinks
    AllowOverride None
    Order deny,allow
#    Deny from all
    Allow from all

#允许所有访问
    Satisfy all
</Directory>

 

 

还有

 

<Directory "D:/Wamp5/www">

    #
    # Possible values for the Options directive are "None", "All",
    # or any combination of:
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    #
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
    # doesn't give it to you.
    #
    # The Options directive is both complicated and important.  Please see
    # http://httpd.apache.org/docs/2.2/mod/core.html#options
    # for more information.
    #
    Options Indexes FollowSymLinks

    #
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   Options FileInfo AuthConfig Limit
    #
    AllowOverride all

    #
    # Controls who can get stuff from this server.
    #
#   onlineoffline tag - don't remove
    Order Deny,Allow
    Deny from all
    Allow from 127.0.0.1

</Directory>

 

修改成

 

<Directory "D:/Wamp5/www">

    #
    # Possible values for the Options directive are "None", "All",
    # or any combination of:
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    #
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
    # doesn't give it to you.
    #
    # The Options directive is both complicated and important.  Please see
    # http://httpd.apache.org/docs/2.2/mod/core.html#options
    # for more information.
    #
    Options Indexes FollowSymLinks

    #
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   Options FileInfo AuthConfig Limit
    #
    AllowOverride all

    #
    # Controls who can get stuff from this server.
    #
#   onlineoffline tag - don't remove
    Order Deny,Allow
#    Deny from all

#  Allow from 127.0.0.1
    Allow from all

</Directory>

 

然后保存,重启服务,在访问就解决了这个问题。

版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。

相关文章
2059 - authentication plugin 'caching_sha2_password'” mysql8.0 Navicat for mysql 登陆错误
最近在windows服务器部署最新版mysql8.0时发现 navicat for mysql登陆不了。 根据错误提示 2059 - authentication plugin 'caching_sha2_password'” 搜索得知,原来是新版mysql8.0登陆验证改变导致的。
4421 0
PHP错误:Forbidden You don&#39;t have permission to access / on this server.
原文:PHP错误:Forbidden You don't have permission to access / on this server. 今天老大让在xp下搭建一个FTP服务器,一波三折,最后终于在老大的帮助下搞定了。
1342 0
错误代码 missing-signature 错误原因: 缺少签名参数-自查方案
[b]报错截图[/b] [attachment=2253][b]错误原因:[/b] 1.php版本低于5.5 2.把配置私钥的位置,填写成了支付宝公钥或者商户公钥导致。 [color=#ff0000]更多密钥填写错误查看:[url]https://openclub.
1191 0
CodeIgniter 错误: In order to use the Session class you are required to set an encryption key
CodeIgniter SESSION  第一次用 session 遇到这个错误 ,说是要加一个密钥才可以使用,加就加吧,打开 config.php 找到以下代码 /*|-----------------------------------------------------------------...
616 0
+关注
杰克.陈
一个安静的程序猿~
10427
文章
2
问答
文章排行榜
最热
最新
相关电子书
更多
《2021云上架构与运维峰会演讲合集》
立即下载
《零基础CSS入门教程》
立即下载
《零基础HTML入门教程》
立即下载