time zone warning

Popular automatic website translation tool

time zone warning

Postby amir00251 » Sun Nov 20, 2011 4:19 pm

Hello,

I get this warning when selecting other languages on site.

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 'UTC' for 'GMT/0.0/no DST' instead in /var/www/vhosts/domain.com/httpdocs/gtranslate/translate.php on line 421


Is there any solution. I get that even when error display is set to none.
amir00251
 
Posts: 9
Joined: Wed Sep 07, 2011 5:08 am

Re: time zone warning

Postby Edvard » Sun Nov 20, 2011 4:42 pm

It is your PHP configuration. If you google the error you get you will find a solution.
Regards,

Edvard Ananyan - GTranslate Team

Please leave your feedback on your CMS plugin directory. It is very important for us!
Google Translate Joomla
Google Translate WordPress
Google Translate Drupal
Edvard
Site Admin
 
Posts: 4185
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia

Re: time zone warning

Postby Jarrell22 » Mon Nov 21, 2011 2:58 pm

There was a reason I didn't do that in the first place, but I agree we need a fallback setting now. I can't believe PHP is yelling about this, but anyway...
One change is needed, I have to make it:
<?php
if (function_exists('date_default_timezone_set')) {
date_default_timezone_set(date_default_timezone_name());
}
?>
Because in Drupal 6 we still support PHP4, where that function does not exist. We won't need that test in Drupal 7.
Jarrell22
 
Posts: 3
Joined: Fri Nov 18, 2011 2:41 pm

Re: time zone warning

Postby Edvard » Mon Nov 21, 2011 3:55 pm

If you have access to php.ini file you can set a correct timezone there otherwise you can solve that issue with your hosting provider.
Regards,

Edvard Ananyan - GTranslate Team

Please leave your feedback on your CMS plugin directory. It is very important for us!
Google Translate Joomla
Google Translate WordPress
Google Translate Drupal
Edvard
Site Admin
 
Posts: 4185
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia


  • Related Topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 0 guests

2GLux