htaccess的 - 网络服务器错误500的XAMPP [英] htaccess - internet server error 500 on XAMPP

查看:605
本文介绍了htaccess的 - 网络服务器错误500的XAMPP的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在XAMPP运行脚本,但拿到网络服务器错误500。其优良的现场服务器上运行时。我认为这是一个错误的.htaccess。 htaccess的code是如下:

I am trying to run script on XAMPP but get "internet server error 500". Its fine when running on the live server. I assume this is a .htaccess error. The htaccess code is below:

<IfModule mod_rewrite.c>
    RewriteEngine on
    RewriteRule    ^$    public/    [L]
    RewriteRule    (.*) public/$1    [L]
 </IfModule>

我已经启用.htaccess中取消注释行:

I have enabled htaccess by uncommenting the line:

的LoadModule rewrite_module模块/ mod_rewrite.so

LoadModule rewrite_module modules/mod_rewrite.so

在配置文件中。

任何想法?

推荐答案

尝试编辑这部分在的httpd.conf ,并设定的AllowOverride全部

Try editing this part in your httpd.conf and set AllowOverride All

#
# 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

或者试试这个:

<Directory />
     AllowOverride All
</Directory>

这篇关于htaccess的 - 网络服务器错误500的XAMPP的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆