Hi guys,
My admin login screen has suddenly stopped working for no apparent reason. When I enter my username and password and click login, the screen just refreshes. I do not receive any errors. I am using using OC 2.0.3.1, it has been working fine up until today.
Any ideas?
So it appears to be something to do with my 301 redirects in my .htaccess file:
If I comment out the last two lines, these redirect the index.php to the domain root, it solves the login problem.
This is a problem as I need to redirect all versions of the homepage to the domain root.
Code: Select all
Options +FollowSymlinks
RewriteEngine on
RewriteBase /
RewriteCond %{HTTPS} off
# First rewrite to HTTPS:
# Don't put www. here. If it is already there it will be included, if not
# the subsequent rule will catch it.
RewriteRule .* https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
# Now, rewrite any request to the wrong domain to use www.
# [NC] is a case-insensitive match
RewriteCond %{HTTP_HOST} !^www\. [NC]
RewriteRule .* https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
RewriteCond %{QUERY_STRING} ^route=product/special$
RewriteCond %{REQUEST_METHOD} !^POST$
RewriteRule ^index\.php$ https://%{HTTP_HOST}/gothic-jewellery-sale? [R=301,L]
RewriteCond %{THE_REQUEST} ^.*/index.php
RewriteRule ^(.*)index.php$ https://www.thealtbox.co.uk/$1 [R=301,L]
This is a problem as I need to redirect all versions of the homepage to the domain root.
The Alt Box, built using Opencart 2.0.3.1.
try to place the Code like this in the .htaccess file.
Ernie
Ernie
Code: Select all
Options +FollowSymlinks
RewriteEngine on
RewriteCond %{HTTPS} off
# First rewrite to HTTPS:
# Don't put www. here. If it is already there it will be included, if not
# the subsequent rule will catch it.
RewriteRule .* https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
# Now, rewrite any request to the wrong domain to use www.
# [NC] is a case-insensitive match
RewriteCond %{HTTP_HOST} !^www\. [NC]
RewriteRule .* https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
RewriteCond %{QUERY_STRING} ^route=product/special$
RewriteCond %{REQUEST_METHOD} !^POST$
RewriteRule ^index\.php$ https://%{HTTP_HOST}/gothic-jewellery-sale? [R=301,L]
RewriteCond %{THE_REQUEST} ^.*/index.php
RewriteRule ^(.*)index.php$ https://www.thealtbox.co.uk/$1 [R=301,L]
RewriteBase /
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Who is online
Users browsing this forum: No registered users and 428 guests