htaccess在cPanel上不起作用,但在WampServer上运行良好



当我试图在使用cpanel的服务器上发布我的网站时,我遇到了一个错误,该网站在wampserver中运行良好,我认为问题可能来自为我生成500错误的htaccess文件

这是我的htaccess

php_flag display_errors on
php_value error_reporting 9999
RewriteEngine On
RewriteBase /  (because my files are in public_html)
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule ^(.+)$ index.php?url=$1 [QSA,L]

这是我第一次使用stackoverflow,请帮我

如果有人经过这里,只需从yout.htaccess中删除php_flag和php_value,因为有些托管公司不允许用户使用它们,比如我的

最新更新