Previous Thread
Next Thread
Print Thread
Rate Thread
Joined: Jan 2000
Posts: 5,833
Likes: 20
UBBDev / UBBWiki Owner
Time Lord
UBBDev / UBBWiki Owner
Time Lord
Joined: Jan 2000
Posts: 5,833
Likes: 20
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...


UBB.Dev - Putting Dev into UBB.threads
Company: VNC Web Services - UBB.threads Scripts and Scripting, Install and Upgrade Services, Site and Server Maintenance.
Forums: A Gardeners Forum, Scouters World, and UGN Security
UBB.Threads: My UBB Themes, My UBB Scripts
Sponsored Links
Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
Nice mod gizzy, never thought of this smile


- Allen wavey
- What Drives You?
Joined: Jan 2000
Posts: 5,833
Likes: 20
UBBDev / UBBWiki Owner
Time Lord
UBBDev / UBBWiki Owner
Time Lord
Joined: Jan 2000
Posts: 5,833
Likes: 20
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.Dev - Putting Dev into UBB.threads
Company: VNC Web Services - UBB.threads Scripts and Scripting, Install and Upgrade Services, Site and Server Maintenance.
Forums: A Gardeners Forum, Scouters World, and UGN Security
UBB.Threads: My UBB Themes, My UBB Scripts

Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
isaac
isaac
California
Posts: 1,157
Joined: July 2001
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)