Previous Thread
Next Thread
Print Thread
Rate Thread
Joined: Sep 2003
Posts: 488
Code Monkey
Code Monkey
Joined: Sep 2003
Posts: 488
Mod Name / Version: Time-Offset Support for IIP Index Page

Description: This adds time-offset support for those who have IIP installed. 'News' posts will now display the correct time for registered users. ie. the same time that is displayed for them on the message boards.

NOTE: This modification is *only* for those who specifically have their news section set to 'disable cache' in the IIP configuration settings. ie '0' in the box where it states...

"Should we cache this information to decrease page generation times?
If so, how many minutes should lapse before updating? ( 0 disables )
(this option used only when force public is turned on above)"

...otherwise it will simply have no effect.


Working Under: UBB.Threads 6.3-6.4-6.5

Mod Status: Finished

Any pre-requisites: IIP Installed

Author(s): Twisty

Date: 08/15/04

Credits:

Files Altered: pals/newspal.php

New Files:

Database Altered: no

Info/Instructions: In newspal.php


1-A) CHANGE THIS:

Code
   $date = $html -> get_date();


TO THIS:

Code
// ----------------- <br />// Get the user info <br />   $userob = new user; <br />   $user = $userob -> authenticate("U_TimeOffset"); <br />   $Username = $user['U_Username']; <br />   $toffset = ""; <br />   isset($user['U_TimeOffset']) && $toffset = $user['U_TimeOffset']; <br />   $date = $html -> get_date();



1-B) CHANGE THIS:

Code
							$date = $html -> convert_time($palPosted);


TO THIS:

Code
							$date = $html -> convert_time($palPosted,$toffset);



Disclaimer: Please backup every file that you intend to modify.
If the modification modifies the database, it's a good idea to backup your database before doing so.

Note: If you modify your UBB.Threads code, you may be giving up your right for "official" support from Infopop.If you need official support, you'll need to restore unmodified files.

Sponsored Links

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
Bill B
Bill B
Issaquah, WA
Posts: 87
Joined: December 2001
Forum Statistics
Forums63
Topics37,575
Posts293,932
Members13,824
Most Online6,139
Sep 21st, 2024
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,835
Greg Hard 4,625
Top Posters(30 Days)
Gizmo 1
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2025 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.1
(Snapshot build 20240918)