loop redirect problem when redirect http to https at htaccess
-
Hello!
I’ve got a problem redirecting to https: I’ve just the certificated with my server and I’m trying to change the .htaccess but it is giving me problems.
First I changed in WordPress panel, in Settings/General http to https, in my case
https://sierraysol.com to https://sierraysol.comAfter I went to the .htaccess file where I had:
#Redirect 301 /es/ https://www.sierraysol.com/guided-hiking-tours-spain/ #Redirect 301 /en/ https://www.sierraysol.com/guided-hiking-tours-spain/ # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress
and I add the two lines:
#Redirect 301 /es/ https://www.sierraysol.com/guided-hiking-tours-spain/ #Redirect 301 /en/ https://www.sierraysol.com/guided-hiking-tours-spain/ # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://sierraysol.com/$1 [R,L] RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress
When I did this, I went to the website: https://sierraysol.com and it says
redirect loop
and it doesn’t work and If I leave the .htaccess as at the beginning, it shows the website without https.
The only parts where https works is in the login and admin panel, the rest https doesn’t work and I don’t know what else to change.I would be very grateful if someone can help me.
Thank you very much in advance
Best,
Zaida
- The topic ‘loop redirect problem when redirect http to https at htaccess’ is closed to new replies.