.htaccess重定向过多

时间:2019-04-21 20:50:27

标签: php .htaccess vds

我有网站。在以前的主机上,.htaccess文件没有任何问题。 现在我对TOO_MANY_REDIRECTS有一些疑问。 我需要将所有请求从yzerkalo.ruwww.yzerkalo.ru重定向到https://** 我有这个.htaccess文件:

RewriteEngine On
RewriteBase /
php_flag display_errors Off

RewriteCond %{HTTPS} !=on
RewriteRule ^.*$ https://%{SERVER_NAME}%{REQUEST_URI} [R,L]
RewriteCond %{HTTP_HOST} ^www.yzerkalo\.ru$ [NC]
RewriteRule ^(.*)$ https://yzerkalo.ru/$1 [R=301,L]

RewriteRule ^sitemap\.xml$ sitemap.xml [L]


RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [L]
RewriteRule ^.*$ index.php [L]

# One month for most static assets
<filesMatch ".(css|jpg|jpeg|png|gif|js|ico)$">
Header set Cache-Control "max-age=2628000, public"
</filesMatch>

我做错了什么? 这就是我在Google Chrome enter image description here

中看到的

1 个答案:

答案 0 :(得分:0)

尝试一下。

command === 'resolveRequest'
相关问题