LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Squirrelmail Warning (https://www.linuxquestions.org/questions/linux-software-2/squirrelmail-warning-784060/)

Rocktron 01-22-2010 12:21 PM

Squirrelmail Warning
 
Hi again, i have installed Squirrelmail 1.4.19 on my RHEL 5.1, it's working fine (at least all the test i have made) but there are warnings messages that i want to fix. This messages are like this:

Code:

Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are
*required* to use the date.timezone setting or the date_default_timezone_set() function. In case you
used any of those methods and you are still getting this warning, you most likely misspelled the
timezone identifier. We selected 'America/Chicago' for 'CST/-6.0/no DST' instead in
/var/www/html/squirrelmail/src/left_main.php on line 388

Warning: strtotime() [function.strtotime]: It is not safe to rely on the system's timezone settings.
You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In
case you used any of those methods and you are still getting this warning, you most likely
misspelled the timezone identifier. We selected 'America/Chicago' for 'CST/-6.0/no DST' instead in
/var/www/html/squirrelmail/functions/date.php on line 428

Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are
*required* to use the date.timezone setting or the date_default_timezone_set() function. In case you
used any of those methods and you are still getting this warning, you most likely misspelled the
timezone identifier. We selected 'America/Chicago' for 'CST/-6.0/no DST' instead in
/var/www/html/squirrelmail/functions/date.php on line 95

How do i fix this? Can someone help?

Also the "function.date" and "function.strtotime" are missed. Could be this the reason?. HOw do i create them?

rweaver 01-22-2010 12:54 PM

It doesn't like the identifier you used for timezone.

The quick dirty fix is change to

date_default_timezone_set("America/Chicago");

in the mentioned scripts. The correct method would be correct date/timezone in your php.ini and squirrelmail configuration.

Rocktron 01-22-2010 01:06 PM

But the scripts are not there. How do I create them? What should i write on them?

rweaver 01-22-2010 01:43 PM

You're saying:
/var/www/html/squirrelmail/functions/date.php
doesn't exist?

try this: updatedb && locate date.php

The easier and more correct method is to fix the config or php.ini file.

Rocktron 01-23-2010 10:38 AM

/var/www/html/squirrelmail/functions/date.php does exist, what doesn't exist are [function.date] and [function.strtotime] that i thing, should exist because each one of them are links to a file that is not there in the scr location.

In the php.ini file i modified the "date.timezone" part and this is how i set it:

;http://www.php.net/manual/en/datetim....date.timezone
date.timezone = "America/Mexico_City"

Is this OK?, or do i have to modify more things and create function.date and function.strtotime

Rocktron 01-23-2010 10:55 AM

OK, thanks to all of you for your help

To solve it i just had to insert the line

date_default_timezone_set('America/Mexico_City');

in the date.php file, i hope this helps some other people


All times are GMT -5. The time now is 01:53 PM.