I have just switched v2.0.1.1 to https.
Settings --> Server Use SSL = yes
Root config file:
// HTTP
define('HTTP_SERVER', 'https://www.mydomain.co.uk/');
// HTTPS
define('HTTPS_SERVER', 'https://www.mydomain.co.uk/');
Admin config file:
// HTTP
define('HTTP_SERVER', 'https://www.mydomain.co.uk/admin/');
define('HTTP_CATALOG', 'https://www.mydomain.co.uk/');
// HTTPS
define('HTTPS_SERVER', 'https://www.mydomain.co.uk/admin/');
define('HTTPS_CATALOG', 'https://www.mydomain.co.uk/');
root .htaccess file:
#permanent redirect to www and https
RewriteEngine On
RewriteCond %{HTTP_HOST} ^mydomain\.co.uk [NC] [OR]
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://www.mydomain.co.uk/$1 [R,L]
Before the switch to https all requests were redirected to www. Since the swicth, all requests, no matter how prefixed are redirecting as expected ie https://www.mydomain etc.
Any suggestions would be appreciated. I am using Nitro Pack for caching and get the same missing icons whether this is enabled or not.
Thanks in advance
XForm - Opencart Form Builder
Xshippingpro - An advanced Shipping Module
Need Professional support? Skype: opencartmart
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
XForm - Opencart Form Builder
Xshippingpro - An advanced Shipping Module
Need Professional support? Skype: opencartmart
My htaccess:
Code: Select all
# 1.To use URL Alias you need to be running apache with mod_rewrite enabled.
# 2. In your opencart directory rename htaccess.txt to .htaccess.
# For any support issues please visit: http://www.opencart.com
Options +FollowSymlinks
# Prevent Directoy listing
Options -Indexes
# Prevent Direct Access to files
<FilesMatch "\.(tpl|ini|log)">
Order deny,allow
Deny from all
</FilesMatch>
# SEO URL Settings
RewriteEngine On
#RewriteCond %{HTTPS} on
#SSL Port
RewriteCond %{SERVER_PORT} !=443
# Remove www. from any domain query
RewriteCond %{HTTP_HOST} ^www.(.*)$ [NC]
RewriteRule ^(.*)$ https://%1%{REQUEST_URI} [R=301,L]
# All broswer request get redirected to HTTPS
RewriteCond %{SERVER_PORT} ^80$
RewriteRule ^.*$ https://%{SERVER_NAME}%{REQUEST_URI} [R=301,L]
# If your opencart installation does not run on the main web folder make sure you folder it does run in ie. / becomes /shop/
RewriteBase /
RewriteRule ^sitemap.xml$ index.php?route=feed/google_sitemap [L]
RewriteRule ^googlebase.xml$ index.php?route=feed/google_base [L]
RewriteRule ^download/(.*) /index.php?route=error/not_found [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !.*\.(ico|gif|jpg|jpeg|png|js|css)
RewriteRule ^([^?]*) index.php?_route_=$1 [L,QSA]
RewriteCond %{HTTP_HOST} ^www\.yourdomain\.com [NC]
RewriteRule ^(.*)$ http://yourdomain.com/$1 [L,R=301]
RewriteCond %{HTTPS} !on
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}
As I'm having the same issue.
Using opencart 3.0.3.2 - PHP 7.4 - Standard Template - Add to Cart Enable Disable Out of Stock Product 3.x - Export/Import Tool (V3.22) for OpenCart 3.x - Footer Social Media Link( 3.x ) v1.0
you could change the font-awesome.css link, to make it as shown below, in your
...theme/template/common/header.tpl:
//maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css
STILL, the correct way to run OC is, to re-route a URL in the .htaccess file, to look like,
as declared in the config.php Files, by use of something like this:
(Rerouting http(s)://SITE Calls to http(s)://www.SITE)
Code: Select all
#Force (http host) non www to www (optional)
RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]
#Force (https host) non www to www (optional)
RewriteCond %{HTTPS} on
RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]
Ernie
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.
Users browsing this forum: No registered users and 245 guests