【问题标题】:DirectoryIndex seemingly ignored by apache2DirectoryIndex 似乎被 apache2 忽略了
【发布时间】:2012-03-08 10:30:30
【问题描述】:

我正在安装 Wordpress 并遇到找不到 index.php 的问题。当然,如果我明确输入它,那很好。问题在于 DirectoryIndex 不正确。我查看 mods-enabled/dir.conf 并显示:

<IfModule mod_dir.c>
  DirectoryIndex index.php index.html index.cgi index.pl index.xhtml index.htm
</IfModule>

这似乎是正确的。但它不起作用。我想也许某处的其他文件正在覆盖它,但如果是这样,它不在启用 mods 中,因为我 grepped 了那个文件夹。

有什么想法吗?

【问题讨论】:

  • 实际加载了 mod_dir 吗?更有可能是由防止 mod_dir 看到目录请求的虚假重写规则引起的。

标签: apache2 directoryindex


【解决方案1】:

我认为 mod_dir 没有加载,尝试命令“sudo a2enmod dir”和“service apache2 restart”

【讨论】:

    猜你喜欢
    • 2021-10-28
    • 2016-09-30
    • 2012-03-11
    • 1970-01-01
    • 1970-01-01
    • 2017-12-05
    • 2015-12-11
    • 2014-04-15
    • 1970-01-01
    相关资源
    最近更新 更多