我已经安装了具有以下重写规则的应用程序。 它运行良好的VPS设置 – 但在每个共享主机显示500错误。 日志显示“bad delimiter” – 尝试一段时间后,我完全无能为力。 请帮忙
<IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteRule ^assets/css/(.*) /wp-content/themes/liinks theme/assets/css/$1 [QSA,L] RewriteRule ^assets/js/(.*) /wp-content/themes/liinks theme/assets/js/$1 [QSA,L] RewriteRule ^assets/img/(.*) /wp-content/themes/liinks theme/assets/img/$1 [QSA,L] RewriteRule ^plugins/(.*) /wp-content/plugins/$1 [QSA,L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule>
谢谢
虽然我不确定这是不是罪魁祸首,但是需要特别对待URL中的空间,在这种情况下,用\逃脱空间。
车削
/wp-content/themes/liinks theme/assets/css/$1
成
/wp-content/themes/liinks\ theme/assets/css/$1
应该解决一个可能的问题。