【问题标题】:Edit page 404 (html)编辑页面 404 (html)
【发布时间】:2015-04-21 23:32:25
【问题描述】:

我无法更改我网站的 404 页面。 我创建了页面errore.html 并创建了文件.htaccess

ErrorDocument 404 /errore.html

但仍会在网站上显示默认的 404 页面。

文件errore.html.htaccess 都在站点的根文件夹中。

【问题讨论】:

  • 检查你的虚拟主机是否允许 htaccess
  • 如何更改权限。我靠服务器 one.com
  • 修改配置文件后还需要重启apache(.htaccess是配置文件)。
  • 抱歉无知。我如何升级 apache

标签: php html webserver http-status-code-404


【解决方案1】:

确保您的 httpd.conf 文件中的设置正确。

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

【讨论】:

  • httpd.conf有什么设置?
  • 这是您在我们的 apache 文件夹中找到的 apache 设置。
  • htaccess 使用 ctrl-F。它给了你我上面给出的代码
  • 你是在服务器还是本地主机上?
  • 我无法根据您的服务器确切地告诉您,但通常它位于您的 public_html 上方的目录中(您的所有站点文件都在其中)。另外,请确保您的 .htaccess 在您的 public_html 文件夹中。
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2010-10-19
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2015-04-04
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多