Page 1 of 1
Vesta is Crazy
Posted: Tue Nov 04, 2014 1:38 pm
by guineapig
I have a domain with SSL added
When I browse with
https://mydomain.com the site loads when I browse with
http://mydomain.com the default page loads..
Its driving me crazy..
Re: Vesta is Crazy
Posted: Tue Nov 04, 2014 1:50 pm
by Milka
It's pretty simple though ;-)
Do I understand correctly that you want to direct the http visitors to https automatically? You can force visitors to use SSL by creating a file in your public_html folder. The file should be called
.htaccess and it should contain the following:
Code: Select all
RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://www.example.com/$1 [R,L]
Re: Vesta is Crazy
Posted: Tue Nov 04, 2014 2:39 pm
by guineapig
Sir,
Thank you for the reply. I do not want to redirect the visitors to https because there are too many mixed contents issue which I have to fix.. the problem is the site loads in https but not in http .. before it used to load properly in http.. this change I saw after I installed the SSL certificate..
the template broke because there were to many mixed contents issue.. so I started converting links to // and am trying to check for both http and https version but not being able to.
Re: Vesta is Crazy
Posted: Tue Nov 04, 2014 4:40 pm
by Milka
Excuse me being a bit rude, but please allow me to make this very clear: Your inability or incapability to develop a proper website is not a Vesta issue. Calling Vesta crazy is bollocks. You're trying to create a workaround for a problem that shouldn't exist in the first place. You need to fix the mixed content issues in your website code.
Re: Vesta is Crazy
Posted: Wed Nov 05, 2014 12:46 am
by szimre
Hi!
When you're adding the SSL cert you have a choice to use public_html or public_shtml. The reason that http and https is different is that you might be using the https directory for the ssl. If you set it to use the normal http directory that might help solving the problem as both of http and https would load the same content. (You still have to fix your coding issues, then you can download the force-https nginx template to force all of your visitors to be redirected to the https version)
Re: Vesta is Crazy
Posted: Thu Nov 06, 2014 7:19 pm
by Vince
Do I understand correctly that you want to direct the http visitors to https automatically? You can force visitors to use SSL by creating a file in your public_html folder. The file should be called
.htaccess and it should contain the following:
Code: Select all
RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://www.example.com/$1 [R,L]
Thank you for posting that Milka!
I did install custom force-https nginx template as outlined in the documentation. However, I am the only user and do not know how change my existing package to the force-https package.
The .htaccess file works fine.
Thanks again!
Re: Vesta is Crazy
Posted: Mon Nov 24, 2014 3:38 pm
by nelblack
guineapig wrote:Sir,
Thank you for the reply. I do not want to redirect the visitors to https because there are too many mixed contents issue which I have to fix.. the problem is the site loads in https but not in http .. before it used to load properly in http.. this change I saw after I installed the SSL certificate..
the template broke because there were to many mixed contents issue.. so I started converting links to // and am trying to check for both http and https version but not being able to.
I have the same problem here. After install the SSL Certificates, the domain will auto redirect to https://, I just need SSL-encrypted when users process to checkout page on my e-commerce site. And I try to turn off the nginx support and domain won't redirect to https:// but lost the SSL support.
So I think the problem is came form VestCP or nginx's conf because I just backup whole site form cPanel/WHM to VestCP.
Re: Vesta is Crazy
Posted: Mon Nov 24, 2014 8:06 pm
by imperio