MyBB Community Forums

Full Version: SSL problem - links are http://
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello,
I did a lot of work on my forum, and in the end its finally under working SSL certficiate if forum is entered through https://.
But!


The forum is not showing itself correctly, many elements are invisible and the overall forum looks like the page is not fully loaded. I called my hosting service to ask them the reason.  They helped and pointed me into the right direction:
SOME OF THE LINKS OF MY MAIN FORUM WEBSITE ARE STARTING WITH HTTP instead of HTTPS. 


For example:

http://www.websitename.com/forum/images/theme name/forumlogo2.png

http://www.websitename.com/forum/images/theme name/collapse.png

http://www.websitename.com/forum/task.php

The forum source code tells me that there is exactly 52 of those http links.

I have absoutely no idea how can I fix it manually. 

I tried to download some of my public_html .php files onto desktop and find the "http" links.. and I have found exactly nothing.


How can I fix it? Maybe there is some plugin that can replace the wrong links?


Thanks in advance
How does your .htaccess look like?

Try with adding this code at top of your .htaccess

RewriteRule ^([^&]*)&(.*)$ https://example.com/$1?$2 [L,QSA,R=301]

Change example.com with your url
Hmm... I didnt try it, but why not.
Just of curiousity - whats the effect of this code? I am curious Smile

EDIT: Okay I added it onto my website public_html and didnt work out..
Isnt there any other way?
Ramireo have you changed the board url in settings?
ACP -> Configuration -> Site Details -> Board URL

Then, also in this page you should enable setting Secure Cookie Flag
Change board URL as chack1172 told, rename your htaccess.txt to .htaccess
then upload the file (with other words: dot htaccess JUST THAT .htaccess
(08-07-2018, 09:39 AM)Ramireo Wrote: [ -> ]Hmm... I didnt try it, but why not.
Just of curiousity - whats the effect of this code? I am curious Smile

EDIT: Okay I added it onto my website public_html and didnt work out..
Isnt there any other way?

1. goto inch/settings.php and replace your domain URL from http:// to https://

2. Change your website url in .htaccess from http:// to https://

3. add this code into your .htaccess file

RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^/(.*):NOSSL$ http://www.example.com/$1 [R=301,L]

Then all your http:// links also direct correctly to https://
(08-08-2018, 02:46 AM)freeeducation365 Wrote: [ -> ]
(08-07-2018, 09:39 AM)Ramireo Wrote: [ -> ]Hmm... I didnt try it, but why not.
Just of curiousity - whats the effect of this code? I am curious Smile

EDIT: Okay I added it onto my website public_html and didnt work out..
Isnt there any other way?

1. goto inch/settings.php and replace your domain URL from http:// to https://

2. Change your website url in .htaccess from http:// to https://

3. add this code into your .htaccess file

RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^/(.*):NOSSL$ http://www.example.com/$1 [R=301,L]

Then all your http:// links also direct correctly to https://

This isn't correct. If you directly edit inc/settings.php file and then you'll edit settings in ACP he will loose the changes.
(08-08-2018, 10:33 AM)chack1172 Wrote: [ -> ]
(08-08-2018, 02:46 AM)freeeducation365 Wrote: [ -> ]
(08-07-2018, 09:39 AM)Ramireo Wrote: [ -> ]Hmm... I didnt try it, but why not.
Just of curiousity - whats the effect of this code? I am curious Smile

EDIT: Okay I added it onto my website public_html and didnt work out..
Isnt there any other way?

1. goto inch/settings.php and replace your domain URL from http:// to https://

2. Change your website url in .htaccess from http:// to https://

3. add this code into your .htaccess file

RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^/(.*):NOSSL$ http://www.example.com/$1 [R=301,L]

Then all your http:// links also direct correctly to https://

This isn't correct. If you directly edit inc/settings.php file and then you'll edit settings in ACP he will loose the changes.

Yes, that is correct because of this line being incorrect in .htaccess → RewriteRule ^/(.*):NOSSL$ http://www.example.com/$1 [R=301,L]

This is the correct line → RewriteRule ^([^&]*)&(.*)$ https://luxorforums.com/$1?$2 [L,QSA,R=301]  (as defined for my website)

The big difference is the 's' in the 'https', then the settings in the AdminCP as stated by @freeeducation365 would be correct.
Okay.
What I did is simply going into:
ACP -> Configuration -> Site Details -> Board URL and changed http:// to https://.
Now it loads correctly!
Thanks for help!

Okay.. this is a nightmare..

After this change today I can not log into admin or any user..

I tried changing inc/settings.php (changed the https back to http).. and.. still can not login

What the heck!