UBB.Dev
I have a friend who can only access my site via SSL (hardcore security policies at his cushy govt job), and everywhere that uses the "full_url" breaks his browsing via SSL and pops him to the normal page (making a post, creating a topic, replying, pms, logging in, etc)...

So I got the bright idea tonight to hack in full SSL support via tweaking with the full url string in the array in the config.inc.php...

It's fairly easy to do, but only tested on PHP5 (though it should work on PHP4).

In includes/config.inc.php:
Find:
Code
//	Note: If you modify ANY code within your UBB, we at Groupee, Inc
// cannot offer you support -- thus modify at your own peril :)

Add After:
Code
$ssl = $_SERVER["HTTPS"];
$url = $_SERVER["HTTP_HOST"];
if($ssl == "on") { $https = "https"; }
else { $https = "http"; }

Then Find:
Code
#  'FULL_URL' => 'http://www.yourdomain.tld/path',

Replace With:
Code
  'FULL_URL' => $https . '://' . $url . '/yourpath',

It'll take and change "http" with "https" if ssl is being used, else it'll take and use "http". Also I set $url to identify if a user is accessing my forum from another domain name (as I have several).

It should work on any Apache based UBB.Threads install with PHP4/5 though...
Posted By: AllenAyres Re: Quick Update for FULL SSL support... - 01/07/2007 2:53 AM
Nice mod gizzy, never thought of this smile
Posted By: Gizmo Re: Quick Update for FULL SSL support... - 01/07/2007 4:06 AM
Yeh, it works lovely lol.. Granted my reasoning is to bypass web filters lol...

He posted toay from work without issue, so thats good; he's been so swamped at work that he hasn't been able to visit (cas they have out site blocked for some reason; yet he can get to 2600.net just fine)...

It's amazing how painless it was though lol... i haven't checked if updating the paths page on the forum clears this mod though, should be something to check out lol...

I don't see why it wouldn't work on php4 though, i checked some old code i used to do something similar and it is near identicle, so it should work fine. And I don't really see why it wouldn't work on IIS either.
© UBB.Developers