.htaccess:Removing/index.php/foo
我有一个用康托建的网站。我刚刚打开了URL重写,现在.htaccess:Removing/index.php/foo,.htaccess,.htaccess,我有一个用康托建的网站。我刚刚打开了URL重写,现在index.php/foo返回404错误。我试图用 RewriteCond %{REQUEST_URI} ^/index\.php/ RewriteRule ^index.php/(.*) /$1 [R,L] 但这没有帮助 以下是contao factory.htaccess的重写部分以及我添加的全部内容(我编辑了所有评论内容以使其更简短): 重新启动发动机 重写基/ 在这里重写cond%{REQUEST_URI}^/index\.php/
index.php/foo
返回404错误。我试图用
RewriteCond %{REQUEST_URI} ^/index\.php/
RewriteRule ^index.php/(.*) /$1 [R,L]
但这没有帮助
以下是contao factory.htaccess的重写部分以及我添加的全部内容(我编辑了所有评论内容以使其更简短):
重新启动发动机
重写基/
在这里重写cond%{REQUEST_URI}^/index\.php/#我的规则
重写规则^index.php/(.*)/$1[R,L]#我的规则在这里
发动机熄火
重写规则。*\.html$index.php[L]
重写规则^[a-z]{2}/$index.php[L]
重写规则^([a-z]{2})$$1/[R=301,L]
我在这里没有得到什么?没关系。我找到了答案
<FilesMatch "\.(png|gif|jpe?g|js|css|ico|THIS HERE CAUSED IT: --> ***php***|xml|csv|txt|gz|swf|flv|eot|woff|svg|ttf|htm)$">
RewriteEngine Off
</FilesMatch>
发动机熄火
<FilesMatch "\.(png|gif|jpe?g|js|css|ico|THIS HERE CAUSED IT: --> ***php***|xml|csv|txt|gz|swf|flv|eot|woff|svg|ttf|htm)$">
RewriteEngine Off
</FilesMatch>