Jump to content
  • 0

Question

Recommended Posts

  • 0
Posted

Well done mate never heard of HTTP:X-Forwarded-Proto before.

I read it somewhere in stackoverflow, but did not try it. Was looking also how to redirect all requests to https.

  • 0
Posted

No. Why? I actually got mine working.

All requests are redirected to https:// www. my-domain .tld

 

Sounded like you may be based on the header.. but that's alright, if it's working, great!  :blesta:

  • 0
Posted

How can i force blesta to use SSL?

 

Hi mate,

 

I do this using the web server only but have to make sure that Blesta is never configured to handle it (otherwise redirect looping occurs). All order pages have Force Secure Connection (HTTPS) un-checked.

 

For those that are using nginx:

#catch all http 80 and redirect to https 443
server {

      listen 80;
      return 301 https://$host$request_uri;

}

  • 0
Posted

 

Hi mate,

 

I do this using the web server only but have to make sure that Blesta is never configured to handle it (otherwise redirect looping occurs). All order pages have Force Secure Connection (HTTPS) un-checked.

 

For those that are using nginx:

#catch all http 80 and redirect to https 443
server {

      listen 80;
      return 301 https://$host$request_uri;

}

Most resellers have no access to root. So the easiest way is .htaccess :blesta:^_^

  • 0
Posted

And I did not use the internal .htaccess for this: in other words, I left those two lines commented:  :rolleyes:

I then added this immediately after RewriteEngine on


#First rewrite any request to the wrong domain to use the correct one (here www.)
RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
 
#Now, rewrite to HTTPS:
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
 
****This redirects all requests to https://www, if you want you can modify it. :P

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...