当我转到http://example.com/not-here时,我得到一个内部服务器错误而不是 404,这是我的 htaccess 文件(它删除了扩展名,因此 abc.php 可以作为 example.com/abc 访问,而不是example.com/abc.php):
Options +FollowSymlinks
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.+)$ /$1.php [L,QSA]
DirectoryIndex login.php index.php
ErrorDocument 403 /error.php?type=403
ErrorDocument 404 /error.php?type=404
ErrorDocument 500 /error.php?type=500
它非常简单,但我看不到它,任何帮助都可以得到