.htaccess - “Too many redirects” when trying to force https

后端 未结 6 1215
我寻月下人不归
我寻月下人不归 2021-01-31 11:19

I am trying to force a subfolder (/bbb/) of my root domain to show always as https. Also my .htaccess file take care of the extensions of the pages.

I have

6条回答
  •  半阙折子戏
    2021-01-31 12:03

    RewriteCond %{HTTPS} off
    RewriteCond %{HTTP:X-Forwarded-Proto} =http
    RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
    
    Add X-Forwarded-Proto condition instead
    

提交回复
热议问题