【问题标题】:500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request in symfony 5500 Internal Server Error 尝试使用 ErrorDocument 处理 symfony 5 中的请求时遇到错误
【发布时间】:2020-12-14 20:38:03
【问题描述】:

我在共享主机 Cpanel 中托管我的 Symfony 5 应用程序。当我使用 .htaccess 文件时,显示以下错误:

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at webmaster@famousmartbd.com to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

.ht访问代码:

<IfModule mod_rewrite.c>
    Options -MultiViews
    RewriteEngine On
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^ %{ENV:BASE}/public/index.php [L]
</IfModule><IfModule !mod_rewrite.c>
    <IfModule mod_alias.c>
        RedirectMatch 302 ^/$ /public/index.php/
    </IfModule>
</IfModule>

如何解决此错误。请帮帮我。

【问题讨论】:

    标签: php .htaccess symfony


    【解决方案1】:

    配置错误。尝试删除此&lt;IfModule !mod_rewrite.c&gt;

    【讨论】:

      猜你喜欢
      • 2017-08-27
      • 2015-08-16
      • 2016-02-01
      • 1970-01-01
      • 1970-01-01
      • 2016-08-07
      • 2021-11-27
      • 1970-01-01
      相关资源
      最近更新 更多