cloudflare - Cloud flare 301 partially working -


i have .htaccess 301 redirect cloud flare redirects main page not other pages. ex. when domain.com redirects https://domain.com when open domain.com/new-page-html, not redirect https:

below code:

rewriteengine on rewritecond %{http:x-forwarded-proto} =http rewriterule ^ https://%{http_host}%{request_uri} [l,r=301] 

thanks in advance

i think better off doing redirect in cloudflare "page rule". way traffic redirected before arrives server. have special rule http -> https redirection.

see: how redirect visitors https/ssl? on cloudflare

update:

cloudflare has "always use https" switch now. can setup http://domain.com/* , flip on switch , that's it!

enter image description here


Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

ruby on rails - Seeing duplicate requests handled with Unicorn -