PDA

View Full Version : Forum time


InSite
Sun 15th Jun '03, 11:38pm
My server time is set to my local time in England, even though the server itself is in the states. However, the forums time is 5 hours behind since upgrading to vB3.

In the admincp, the time is set to GMT (london).

Have I missed something obvious?

Also, when I installed I changed the config.php file to reflect the following:

$admincpdir = 'admin';
$modcpdir = 'mod';

however, all the links to the admin control panel still point to admincp.

Thanks :)

okrogius
Sun 15th Jun '03, 11:43pm
DId you physically rename the folders to admin from admincp and from modcp to mod?

InSite
Sun 15th Jun '03, 11:45pm
DId you physically rename the folders to admin from admincp and from modcp to mod?

yes... the link on the forum points to admincp, whereas I renamed the folder to admin, and changed the config setting before upgrading :)

okrogius
Mon 16th Jun '03, 12:00am
The style (and as much the footer) templates aren't final. Just append "admin" to your url manually.

InSite
Mon 16th Jun '03, 4:14pm
Bump... Sorry, just making sure it's seen :)

Steve Machol
Mon 16th Jun '03, 5:14pm
Why don't you try reverting to admincp and modcp and renaming those directories?

InSite
Mon 16th Jun '03, 8:54pm
Why don't you try reverting to admincp and modcp and renaming those directories?

It's not a problem for me personally, I was just trying to bring to your attention that the setting in the config.php was ignored during the upgrade...

The real point of this thread was the time problem.

Steve Machol
Mon 16th Jun '03, 9:13pm
For the time problem, you need to set the timezone in the Admin CP to match the timezone of the server your forums are running on. Then each user needs to set their local timezones in the User CP. They also need to take notice of the DST setting (daylight savings time.)

InSite
Mon 16th Jun '03, 9:15pm
Yes... The timezone on the server is set to GMT, as is the timezone in the admin CP. Also, when I am logged in my user CP it is set to GMT. But it is well out of wack...

This is only a problem since upgrading - I have 2 other vBulletins on the same server running vb2 with the same settings.

The server itself is in america, but I have set the server clock to UK time (it's dedicated). Could this be causing a problem?

Steve Machol
Mon 16th Jun '03, 9:36pm
AFAIK if you have this set to the real server time then this should work. I don't really know what else to suggest.

InSite
Wed 18th Jun '03, 11:18am
Is there something in the code that detects the servers actual location time, rather than the timezone the server is set to?

Paul_M
Wed 18th Jun '03, 8:00pm
I've encountered this same problem.

I am in the UK, server time is set to GMT (although server is based in the USA).

My local time is UK, and the admin settings are for GMT... but the clock is very wrong.

On my Vb 2.30 it's fine.

InSite
Wed 18th Jun '03, 8:29pm
Same situation as me then - sorry for you, but thank god - I was beginning to think they were going to ignore me!

Ok - there must be something in the code that is auto-detecting the server timezone. Steve M - I know you've suggested everything you can think of, so could this be moved to the bugs forum?

Thanks :)

InSite
Sat 21st Jun '03, 11:46pm
I was beginning to think they were going to ignore me!

Whyever would I think that? :rolleyes:

Steve Machol
Sat 21st Jun '03, 11:55pm
Sorry but I can't duplicate this problem and confirm it as a bug. When I set the corrwect timezones on my test forum, then the correct times appear.

I think you are right about the auto-detecting though. I think there is something unique about your server that may be misleading vB about the timezone it is in. We'll need a Dev to explain this. Even though I can't confirm it as a bug, I'll move this to the Bugs forum for a Dev to look at.

Mike Sullivan
Mon 23rd Jun '03, 2:11am
Upload the attached script to your main vBulletin directory and either send me the URL or paste its output here.

InSite
Mon 23rd Jun '03, 8:10am
Upload the attached script to your main vBulletin directory and either send me the URL or paste its output here.

Thanks :)

The server hardware and software time is set to 12:12pm. This is the output from your script:

Current time: 1056395907 - Mon Jun 23 12:18:27 MST 2003
Offset from GMT: -25200 (-7)

GMT time: 1056395907 - Mon Jun 23 19:18:27 GMT 2003
Current + offset: 1056421107 - Mon Jun 23 19:18:27 MST 2003

Paul_M
Mon 23rd Jun '03, 8:15am
Upload the attached script to your main vBulletin directory and either send me the URL or paste its output here.
Server time is GMT, at the time I ran this script, my server said it was 11:16am, which it was, 11:16am GMT (12:16am BST (summer time)).

The script output is here:

Current time: 1056392206 - Mon Jun 23 11:16:46 PDT 2003
Offset from GMT: -25200 (-7)

GMT time: 1056392206 - Mon Jun 23 18:16:46 GMT 2003
Current + offset: 1056417406 - Mon Jun 23 18:16:46 PDT 2003

Mike Sullivan
Mon 23rd Jun '03, 1:25pm
Ok, the problem in both cases is how the server time is set. Both said it's running on GMT -- which the actual time is -- but the timezone says it's MST/PDT. Note the "GMT time" line; that was generated with PHP's own gmdate() function, but it's definitely incorrect itself.

You can keep your servers running on GMT, but you need to change the timezone to actually be GMT. That should fix the problem.

Paul_M
Mon 23rd Jun '03, 2:52pm
Ok, the problem in both cases is how the server time is set. Both said it's running on GMT -- which the actual time is -- but the timezone says it's MST/PDT. Note the "GMT time" line; that was generated with PHP's own gmdate() function, but it's definitely incorrect itself.

You can keep your servers running on GMT, but you need to change the timezone to actually be GMT. That should fix the problem.

Bum. I'll have to look at this. I set my server to GMT using the Plesk server admin. I'll check on the time zone!

I'll report back.

Paul_M
Tue 24th Jun '03, 6:45am
OK, I have Plesk Server Admin, and while it can be very useful, it can also be a right pain in the backside.

Anyway, I can get it to work now, the timezone appeared correct (GMT), but the time was wrong for GMT, so I set the time using the date function and all works fine.

Thanks.

Paul

alkahf
Tue 24th Jun '03, 7:21am
Current time: 1056450398 - Tue Jun 24 14:26:38 MSD 2003
Offset from GMT: 14400 (4)

GMT time: 1056450398 - Tue Jun 24 10:26:38 GMT 2003
Current + offset: 1056435998 - Tue Jun 24 10:26:38 MSD 2003

InSite
Tue 24th Jun '03, 8:14pm
You can keep your servers running on GMT, but you need to change the timezone to actually be GMT. That should fix the problem.

Thanks - I just need to find out how to do that. This is a new thing in vB3 then, as it didnt happen with vB2, or any other programs I use.

InSite
Sun 20th Jul '03, 1:20am
Current output from date.php:

Current time: 1058678242 - Sun Jul 20 5:17:22 GMT 2003
Offset from GMT: 0 (0)

GMT time: 1058678242 - Sun Jul 20 5:17:22 GMT 2003
Current + offset: 1058678242 - Sun Jul 20 5:17:22 GMT 2003


To everyone else, I found a good link about changing the timezone on a server: http://www.soapi.com/howto/datetime.htm

Anyways, this now works on both vB2 and vB3 - but only when I'm logged out. When I log in, the "Automatically detect daylight saving" settings kicks in, and adds an hour:

All times are GMT +1 hour. The time now is 06:18

Have I still got something wrong, or is this a bug? I dont want users to have to fiddle with this - I just want to set the local time on my board like I always used to :(