我需要 EasyPHP 和 .htaccess 的帮助。
.htaccess 文件不起作用,我认为这是因为我没有使用 EasyPHP 设置某些内容。
我的 EasyPHP 版本是5.3.8.1
也许有人知道如何解决这个问题?
.htaccess 文件:
Options +FollowSymlinks
RewriteEngine on
RewriteRule ^get/([^/]+) /func/get.php?link=$1 [NC]
EasyPHP 中 Apache 的默认安装没有激活使用 .htaccess 文件修改文件夹中的服务器配置的选项。
您必须告诉 Apache 可以使用 .htaccess 文件更改哪些配置以及在哪个文件夹中。要启用主 Web 服务器上的所有配置更改,您应该编辑http.conf(在 Apache/conf 文件夹中),然后查找:
<Directory "${path}/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 None
#
# Controls who can get stuff from this server.
#
Order allow,deny
Allow from all
</Directory>
并改变
AllowOverride None
to
AllowOverride All
为了更好地对其进行微调,请阅读有关的文档允许覆盖 in:
http://httpd.apache.org/docs/2.2/mod/core.html#allowoverride http://httpd.apache.org/docs/2.2/mod/core.html#allowoverride
另外,检查 http.conf 是否已激活 mod_rewrite,查找:
#LoadModule rewrite_module modules/mod_rewrite.so
并删除前导“#”
LoadModule rewrite_module modules/mod_rewrite.so
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)