• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Move forum from HTTP to HTTPS

kaieivindm

Active member
#1
Hi all,

So I am in the process now, of moving my forum from HTTP to HTTPS. As this will be my first time, I was wondering if the community had some good tips and tricks to offer, and maybe tell me what NOT to do, and best practises.

Thanks!
 

Mr Lucky

Well-known member
#2
Be prepared to lose some revenue if you have Adsense.

I found it quite painless with xenforo, however don't forget the appropriate .htaccess redirect.

Note that since the last upgrade, for any existing image URLs with your old http address you need find and replace with https
 

kaieivindm

Active member
#3
Be prepared to lose some revenue if you have Adsense.

I found it quite painless with xenforo, however don't forget the appropriate .htaccess redirect.

Note that since the last upgrade, for any existing image URLs with your old http address you need find and replace with https
Thanks for the htaccess tips.
According to my research, this is what I need in that file.

Code:
RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^.*$ https://%{SERVER_NAME}%{REQUEST_URI} [R,L]
I don't have any ADS currently on my Forum, so should be OK there.
 

Mr Lucky

Well-known member
#4
This is what I'm using:

Code:
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
I also have a test site (good idea) and decided it was worth the extra for another certificate for that. Not necessary I suppose but useful.
 

kaieivindm

Active member
#5
Good to know.

Is there something else in ACP besides Image Proxy I have to enable? /change/?
Assume I have to change my links on settings to https also.
 

Mr Lucky

Well-known member
#6
Good to know.

Is there something else in ACP besides Image Proxy I have to enable? /change/?
Assume I have to change my links on settings to https also.
I think that's it. Check for any absolute URLs in styles or addons. Note that Image Proxy no longer works when there are redirects, so that is why I said to check for image URLs (to your own site) in posts and resources as these will just show as broken images if Image Proxy is ticked.

Any image URLs in ppsts and resource pointing to external sites that have redirects will also be broken, so if you find them (there may not be many) then you manually need to edit them to the actual URL not the one they are redirected from. I had this issue recently:

https://xenforo.com/community/threads/hosted-images-broken-since-upgrade-patch.120674/#post-1097120
 

StarArmy

Active member
#7
You can use this add-on to convert all your hotlinked images into attachments: https://xenforo.com/community/resources/metamirror.2117/

This will help you avoid "mixed content."

Also make sure any embedded graphics in your forum styles (e.g. your logo) are HTTPS links or you'll get the yellow triangle for mixed content (even if you have a redirect set up IIRC).

For my forum I was able to set up an automatically-renewing free certificate from LetEncrypt.
 
#10
OK - so my forum is now on HTTPS. Was quite a smooth ride. My HOST installed the certificate With no hassle, I changed the .htaccess file and acp settings.

Havent found anything yet, but expect someone to find something rather soon. But looking good so far :)
 

Mr Lucky

Well-known member
#16
Note that Image Proxy no longer works when there are redirects, so that is why I said to check for image URLs (to your own site) in posts and resources as these will just show as broken images if Image Proxy is ticked.
NB: this has been fixed in xenForo 1.5.11