Loading...
 
Features / Usability

Features / Usability


Tiki attaching :80 to HTTPS URLs

posts: 10

Am trying to use SSL on TikiWiki using Let's Encrypt. However when visiting the site through https, there's almost always a :80 add to the url. Web browsers refuse to open the site. Chrome says the site can’t handle secure connection.
I want to know If the problem is from my host or the software.
Is there any special procedure to carry out before using SSL on TikiWiki?

I have something else installed a subdomain of the site where TikiWiki resides. Let's Encrypt works fine on that site. No redirects to port 80.
My webhost support says it's the script (TikiWiki) erroneously making the redirects.

posts: 10
Copy to clipboard
global $base_url; $base_url = str_replace(":80", "", $base_url);


I added this to /tiki-setup.php and the redirect stopped
I don't know if there's a 'more correct'  thing to have done. Other scripts work with SSL on this same host w/o any problems so I guess it has to do with Tiki


posts: 10

Hello am still having the same issues only when users try to link their Social networks to the site. The url sent from Facebook and Twitter contains :80 and the fix above doesn't redirect.
If I remove the :80 and hit enter everything works correctly.


posts: 2428 Czech Republic

Hi,

I do not have any problems with Let's encrypt and Tiki on my VPS (CentOS 6 with Apache). I think it must be something odd at your webhosting setup what is adding the :80 port number to your site...

luci

posts: 10

I really don't know.
I have other cms installed on the same webhost which works fine with Let's Encrypt.



posts: 10

In Control Panel >>Login
Under HTTPS port, the value is always 80.
It always resets to the value of 80 even when I set it to 443 and click save.

posts: 12

I can confirm that I too am experiencing both issues as described by elnelson. I see that port 80 is being inserted into a secure URL, which prevents the web page from rendering in the browser.

Also it is impossible to change the value of 80 to 443 at https://www.calport.com/tiki-admin.php?page=login - I am unable to set it to 443 or to leave it blank. On on submit the value of 80 pops up again in the HTTPS port text box.

posts: 20 United States

The workaround from Niel Hirjee in the above link fixed the issue of :80 being injected into the URL on a secure site. Now I just need to remember to edit the tiki-setup.php file after every upgrade. exclaim

Copy to clipboard
// Added to keep :80 from being injected. global $base_url_https; $base_url_https = str_replace(":80", "", $base_url_https); $base_url_http = str_replace(":80", "", $base_url_http); $base_url = str_replace(":80", "", $base_url);
posts: 20 United States
Just upgraded to Tiki 19 and the HTTPS problem still exists. I am running on Webfaction hosting, but I doubt it is relevant. Continuing to use the workaround!

posts: 12

In tiki17 the issue persists and the following serves as workaround for me:

global $base_url_https;
$base_url_https = str_replace(":80", "", $base_url_https);
$base_url_http = str_replace(":80", "", $base_url_http);
$base_url = str_replace(":80", "", $base_url);

in tiki-setup.php, insert around line 304


posts: 20 United States

This is a serious error, and I am happy to find two others with the exact same problem. Google now penalizes sites that are not HTTPS. I appreciate the workarounds presented in this thread, but this needs to get the attention of the devs. I suspect that not many tikiwiki sites are running on HTTPS, but this one is.

My situation is:

  • I had my site working on HTTPS with Tiki 14
  • Upgraded to Tiki 18, which required a move to a new webserver.
  • Installed to a new webserver with PHP7, imported my old database and files.
  • I had to disable HTTPS in the preferences on the old site so that I could configure it on the new site before I had the new SSL cert up and running.
  • Then I was able to complete the setup and database upgrade.
  • Activating https worked well, but I've spent hours trying to troubleshoot why :80 keeps getting injected, and why the preferences don't let me set 443 as the port for HTTPS.

I wonder if it is because the setup steps that create the .htaccess file were done in HTTP mode, and I wonder if I redo the setup configuration again, now that HTTPS is functioning, that maybe it will get configured correctly. This sounds like a better solution to me than the workaround above.

posts: 20 United States

Thanks, but "Protect all sessions with HTTPS" was already checked. I tested with it checked and unchecked and it makes no difference. I think the core problem is that tikiwiki insists on using port 80 for SSL and doesn't let me change it. Here is video proof:
https://www.loom.com/share/8c56c493e78e428d9cff19c3a51f6ad6

posts: 20 United States
My issue is fixed in Tiki 20
posts: 1630 Canada
Doug Higby wrote:
My issue is fixed in Tiki 20


Yes! Thanks for following up!


Upcoming Events

1)  18 Apr 2024 14:00 GMT-0000
Tiki Roundtable Meeting
2)  16 May 2024 14:00 GMT-0000
Tiki Roundtable Meeting
3)  20 Jun 2024 14:00 GMT-0000
Tiki Roundtable Meeting
4)  18 Jul 2024 14:00 GMT-0000
Tiki Roundtable Meeting
5)  15 Aug 2024 14:00 GMT-0000
Tiki Roundtable Meeting
6)  19 Sep 2024 14:00 GMT-0000
Tiki Roundtable Meeting
7) 
Tiki birthday
8)  17 Oct 2024 14:00 GMT-0000
Tiki Roundtable Meeting
9)  21 Nov 2024 14:00 GMT-0000
Tiki Roundtable Meeting
10)  19 Dec 2024 14:00 GMT-0000
Tiki Roundtable Meeting