.htaccess - redirect non-www to www and http to https -
i switched site on http https can't redirects work correctly. it's site without subdomains.
i following work correctly:
- example.com
https://www.example.com - example.com/whatever-page
https://www.example.com/whatever-page - www.example.com
https://www.example.com - www.example.com/whatever-page
https://www.example.com/whatever-page
i've read lot of .htaccess solutions , tried them. @ moment, i'm using following:
rewriteengine on rewritecond %{http_host} !^www\. rewriterule (.*) https://www.%{http_host}/$1 [r,l] rewritecond %{https} off rewriterule (.*) https://%{http_host}/$1 [r,l] but wont work is: www.example.com/whatever-page https://www.example.com/whatever-page
anyone solution me? appreciate it!
Comments
Post a Comment