Post by kathyarias » Wed Sep 20, 2017 11:39 pm

I have done everything I know of. I made sure config.php has bot http and https directed to https. I also, renamed my httaccess.txt to .httaccess. But when I open my store, all pages are redirected except for my homepage. So i tried to do a redirect with cpanel, and it gives me this message:
There was an error adding the redirect. Redirecting "" to "https://www.mydomain.com/" will cause a redirection loop because "http://mydomain.com/", which is located at "/home/user/public_html/", is above "https://www.mydomain.com/", which is located at "/home/user/public_html/" .

Can someone help me figure out what's going on, please? Thank you

New member

Posts

Joined
Fri Oct 28, 2016 1:30 am

Post by yodapt » Thu Sep 21, 2017 12:20 am

Have you changed anything about the .htaccess file contents?

Opencart Developer - My Extension Showcase
Contact me at aeon.yoda@gmail.com


User avatar
Active Member

Posts

Joined
Fri Jun 17, 2011 6:39 pm


Post by paulfeakins » Thu Sep 21, 2017 5:53 pm

When you do the redirect, take off the trailing slash.

UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk


User avatar
Guru Member
Online

Posts

Joined
Mon Aug 22, 2011 11:01 pm
Location - London Gatwick, United Kingdom

Post by MrPhil » Sun Sep 24, 2017 8:57 pm

Did you really spell the file .httaccess? It's .htaccess (one t).

You want the entire store to be under SSL (https)? Make sure you have all "http:" changed to "https:" in your configure files. In your .htaccess, redirect any http: to https:, and that should do it.

Code: Select all

RewriteEngine On
RewriteCond  %{HTTPS}  !on
RewriteRule  ^(.*)$  https://www.yourstore.com/$1  [R=301,L]
Even better, combine forcing https and using www. in the same redirect:

Code: Select all

RewriteEngine On
RewriteCond  %{HTTPS}  !on  [OR]
RewriteCond  %{HTTP_HOST}  !^www\.   [NC]
RewriteRule  ^(.*)$  https://www.yourstore.com/$1  [R=301,L]

User avatar
Active Member

Posts

Joined
Wed May 10, 2017 11:52 pm
Who is online

Users browsing this forum: julianashcroft and 272 guests