Page 1 of 2
Timezone issues
Posted: 04 Sep 2015, 04:01
by fbrose
Hi Team,
I am unable to get my time entries in order as they seem behind by 12 hours (My Timezone is +5:30 Mumbai IST).
I have tried logging in as the Admin user and changing the time zone settings, logging out as suggested and the logging back in, only to find the same time zone set.
The current time zone set is stuck at +5:00 Ekaterinburg and I am unable to move it anywhere else.
I am running CATS Version 0.9.1 (Beas) on a hosted web server.
Do let me know what needs to be done to resolve this issue.
Warm regards,
Fabian
Re: Timezone issues
Posted: 04 Sep 2015, 10:15
by RussH
Hi Fabian,
timezone is set in config.php, which is in the root directory of the installation.
please edit the entry for the timezone offset you require;
Code: Select all/* Offset to GMT Time. */
define('OFFSET_GMT', 2);
Re: Timezone issues
Posted: 04 Sep 2015, 21:31
by fbrose
Hi Russ, thanks for the update. I did try editing the config.php file and the following is the result:
Adding an activity on 05-09-15 (1:52 AM) appears with a timestamp as 04-09-15 (06:22 PM) and the corresponding entry in the config.php file is:
/* Offset to GMT Time. */
define('OFFSET_GMT', 0);
Similarly,
Adding an activity on 05-09-15 (1:58 AM) appears with a timestamp as 04-09-15 (12:28 PM) and the corresponding entry in the config.php file is:
/* Offset to GMT Time. */
define('OFFSET_GMT', 6);
I am running CATS Version 0.9.1 (Beas) on a shared hosting web server.
Please help me with this issue.
Warm regards,
Fabian
Re: Timezone issues
Posted: 05 Sep 2015, 11:27
by RussH
Possibly another issue from shared hosting. Best place to start is to find out what the shared host thinks the time is.
can you start by finding out what PHP thinks the server date/time is. Create a small file in the opencats root directory called date.php, with the following content;
Code: Select all<?php
echo date('l jS \of F Y h:i:s A');
?>
- then browse to http://your_server/cats/date.php
you should get a one line respone with the date and time from the server. We can take it from there.
For example - if I browse to
http://demo.opencats.org/date.php then I get
Saturday 5th of September 2015 11:24:13 AM
Re: Timezone issues
Posted: 05 Sep 2015, 13:11
by fbrose
Hi Russ,
Thanks for the input - I just ran the date.php on Saturday 5th of September 2015 5:40 PM, and the following is the output: Saturday 5th of September 2015 12:09:43 PM.
Seems like it's set at 0:00 GMT!
Do let me know what you think of this.
Warm regards,
Fabian
Re: Timezone issues
Posted: 05 Sep 2015, 16:36
by RussH
HI Fabian, seems a strange issue. I assume you can just increment the GMT_OFFSET until you reach the correct date/time for new activity entries. Did you try that?
Re: Timezone issues
Posted: 05 Sep 2015, 17:22
by fbrose
Hi Russ, yes it is!
Check this out:
Local time = 9:47 PM, 5th Sept.
Server Time = Saturday 5th of September 2015 04:17:37 PM (From the date.php file run)
Activity timestamp in OpenCATS: 05-09-15 (07:17 PM) made in sync with local and server time above.
Config.php offset entries are below:
Code: Select all/* Offset to GMT Time. */
define('OFFSET_GMT', 0);
Any guesses?
Regards,
Fabian
Re: Timezone issues
Posted: 15 Sep 2015, 10:51
by RussH
Hi fabian,
add in a GMT +2.5 and see what you get?
Re: Timezone issues
Posted: 16 Sep 2015, 12:07
by fbrose
Hi Russ,
Thank you for the response.
I tried with +2.5 at 16:31 on 15-Sept-2015 and the timestamp of an activity shows "16-09-15 (12:05 PM)".
The Date.PHP output is: Wednesday 16th of September 2015 11:05:28 AM
The relevant code is:
Code: Select all/* Offset to GMT Time. */
define('OFFSET_GMT', 2.5);
BTW: do I need to specify a '+' sign before the 2.5 time zone offset in the code above?
Thanks a lot.
Regards,
Fabian
Re: Timezone issues
Posted: 24 Nov 2016, 09:04
by kedar
fbrose wrote:Hi Russ,
Thank you for the response.
I tried with +2.5 at 16:31 on 15-Sept-2015 and the timestamp of an activity shows "16-09-15 (12:05 PM)".
The Date.PHP output is: Wednesday 16th of September 2015 11:05:28 AM
The relevant code is:
Code: Select all/* Offset to GMT Time. */
define('OFFSET_GMT', 2.5);
BTW: do I need to specify a '+' sign before the 2.5 time zone offset in the code above?
Thanks a lot.
Regards,
Fabian
Hi has anyone tried working on this issue?. I have been facing the same issue the godaddy server seems to be on arizona time and i am unable to change it to India time