CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Upgrading CiviCRM (Moderator: Deepak Srivastava) »
  • Solved--Time zone errors- again
Pages: [1]

Author Topic: Solved--Time zone errors- again  (Read 2830 times)

patricr

  • I post occasionally
  • **
  • Posts: 30
  • Karma: 0
Solved--Time zone errors- again
August 21, 2010, 11:48:06 am
(Upgraded from 3.15>3.21 before migration)

I have migrated second CiviCRM site to a new location and have gotten this error, again- many times down the top of several pages in the CiviCRM part of the Drupal install:
========
warning: 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/New_York' for 'EDT/-4.0/DST' instead in /Library/WebServer/Documents/sites/all/modules/civicrm/CRM/Core/BAO/Dashboard.php on line 226.

OR

# warning: mktime(): 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/New_York' for 'EDT/-4.0/DST' instead in /Library/WebServer/Documents/sites/all/modules/civicrm/CRM/Utils/Date.php on line 217.
# warning: strftime(): 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/New_York' for 'EDT/-4.0/DST' instead in /Library/WebServer/Documents/sites/all/modules/civicrm/CRM/Utils/Date.php on line 217.

Lobo has earlier replied that CiviCRM does not use a "timezone." However- the last part of the line says:  civicrm/CRM/Core/BAO/Dashboard.php on line 226.
========
I noted that when I exported the database using PHPmyadmin, it says in the file name save box:

"Filename template 1(superscript) 1

This value is interpreted using strftime, so you can use time formatting strings. Additionally the following transformations will happen: __SERVER__/ server name __DB__/ database name. Other text will be kept as is."

It seems the strftime is being added and that is a problem on import.

Is this a Drupal or a CiviCRM problem? Is there a value in either SQL database I can change to fix it?
« Last Edit: August 23, 2010, 04:08:04 pm by patricr »

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Time zone errors- again
August 21, 2010, 02:11:46 pm

to clarify, i meant:

CiviCRM does not set the timezone field

TO get around this issue, try setting the timezone value in your php.ini. check the php manual for more details on how to do this

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

patricr

  • I post occasionally
  • **
  • Posts: 30
  • Karma: 0
Solution: Time zone errors- again
August 21, 2010, 04:40:55 pm
Thanks- I did a lot of surfing and Googling the web to find many mentions of this problem with PHP 5.3.

In Mac OSX server there are 3 php.ini files! I changed them all, and the final thing that made the errors go away was fixing the .htacces file. I also put a line in the PHP 5 area about timezone.
« Last Edit: August 23, 2010, 04:08:30 pm by patricr »

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Upgrading CiviCRM (Moderator: Deepak Srivastava) »
  • Solved--Time zone errors- again

This forum was archived on 2017-11-26.