Jump to content



Photo

Dashboard - Error Log


This topic has been archived. This means that you cannot reply to this topic.
11 replies to this topic

#1   syscon

syscon
  • Members
  • 268 posts

Posted 02 April 2011 - 13:18

When I login to ver.3 I get error time function:
Dashboard - Error log:

04/02/2011 07:45:22 PHP Warning: strftime() [<a href='function.strftime'>functi..
04/02/2011 07:45:22 PHP Warning: mktime() [<a href='function.mktime'>function.m..
04/02/2011 07:45:22 PHP Warning: date() [<a href='function.date'>function.date<..
04/02/2011 07:45:22 PHP Warning: mktime() [<a href='function.mktime'>function.m..
04/02/2011 07:45:22 PHP Warning: date() [<a href='function.date'>function.date<..
04/02/2011 07:45:22 PHP Warning: strftime() [<a href='function.strftime'>functi..

How to fix it?
#Joseph

#2 ONLINE   Harald Ponce de Leon

Harald Ponce de Leon

    Healthy Giraffe

  • Core Team
  • 4,718 posts

Posted 02 April 2011 - 16:26

Hi Joseph..

Could you post the full error message?

Thanks,
Harald Ponce de Leon

#3   syscon

syscon
  • Members
  • 268 posts

Posted 02 April 2011 - 16:39

Hi Joseph..

Could you post the full error message?

Thanks,


Hi Harald,

Here it is:

PHP Warning: strftime() [<a href='function.strftime'>function.strftime</a>]: 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/Denver' for 'MDT/-6.0/DST' instead in /var/www/localhost/htdocs/sysconcept_ca/oscommerce/osCommerce/OM/Core/DateTime.php on line 37

PHP Warning: mktime() [<a href='function.mktime'>function.mktime</a>]: 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/Denver' for 'MDT/-6.0/DST' instead in /var/www/localhost/htdocs/sysconcept_ca/oscommerce/osCommerce/OM/Core/DateTime.php on line 37

PHP Warning: date() [<a href='function.date'>function.date</a>]: 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/Denver' for 'MDT/-6.0/DST' instead in /var/www/localhost/htdocs/sysconcept_ca/oscommerce/osCommerce/OM/Core/DateTime.php on line 36

PHP Warning: mktime() [<a href='function.mktime'>function.mktime</a>]: 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/Denver' for 'MDT/-6.0/DST' instead in /var/www/localhost/htdocs/sysconcept_ca/oscommerce/osCommerce/OM/Core/DateTime.php on line 36

PHP Warning: date() [<a href='function.date'>function.date</a>]: 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/Denver' for 'MDT/-6.0/DST' instead in /var/www/localhost/htdocs/sysconcept_ca/oscommerce/osCommerce/OM/Core/DateTime.php on line 84

PHP Warning: strftime() [<a href='function.strftime'>function.strftime</a>]: 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/Denver' for 'MDT/-6.0/DST' instead in /var/www/localhost/htdocs/sysconcept_ca/oscommerce/osCommerce/OM/Core/DateTime.php on line 37

Regards,
#Joseph

#4   joshhanson314

joshhanson314
  • Members
  • 4 posts

Posted 02 April 2011 - 22:50

I created a php.ini at my installation's root with the following line and it worked fine.

date.timezone=America/New_York

Obviously use whatever time zone you want. Also, not sure if this is a quick fix to a bigger bug, but it works fine for me now. This might be the best fix for me anyway since my hosting provider's servers are in a different time zone than me anyway, and I'd like it to use my local time zone.

Best,
Josh Hanson

Edited by joshhanson314, 02 April 2011 - 22:52.


#5 ONLINE   Harald Ponce de Leon

Harald Ponce de Leon

    Healthy Giraffe

  • Core Team
  • 4,718 posts

Posted 02 April 2011 - 23:01

Hi Josh..

That is absolutely the best solution to the issue :-) The issue is with an incorrectly configured PHP installation.

We can detect this though and fix appropriately, and will be included in the first v3.0.1 update package.

Kind regards,
Harald Ponce de Leon

#6   syscon

syscon
  • Members
  • 268 posts

Posted 03 April 2011 - 00:58

I created a php.ini at my installation's root with the following line and it worked fine.

date.timezone=America/New_York

Obviously use whatever time zone you want. Also, not sure if this is a quick fix to a bigger bug, but it works fine for me now. This might be the best fix for me anyway since my hosting provider's servers are in a different time zone than me anyway, and I'd like it to use my local time zone.

Best,
Josh Hanson


I've tried your solution, created file php.ini with one line:
date.timezone=Canada/Mountain

in the root directory
/var/www/localhost/htdocs/oscommerce
and restarted apache server.

but it is not working. I've tried to modify: /etc/php/cli-php5.3/php.ini but still same error.
What am I doing wrong?
#Joseph

#7 ONLINE   Harald Ponce de Leon

Harald Ponce de Leon

    Healthy Giraffe

  • Core Team
  • 4,718 posts

Posted 03 April 2011 - 12:06

Hi All..

A bug report has been created to track this issue:

http://forums.oscomm...-time-zone-set/

This issue is actually now fixed and will appear in the v3.0.1 update package that will be published in a few days.

Kind regards,
Harald Ponce de Leon

#8   geoffreywalton

geoffreywalton

    Available for Hire

  • Community Sponsor
  • 8,203 posts

Posted 03 April 2011 - 18:32

Try

America/Montreal

Also see

http://www.php.net/m...nes.america.php

HTH

G
Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

Virus Threat Scanner
My Contributions
Basic install answers.
Click here for Contributions / Add Ons.
UK your site.
Site Move.
Basic design info.

For links mentioned in old answers that are no longer here follow this link Useful Threads.

If this post was useful, click the Like This button over there ======>>>>>.

#9   syscon

syscon
  • Members
  • 268 posts

Posted 03 April 2011 - 20:16

Try

America/Montreal

Also see

http://www.php.net/m...nes.america.php

HTH

G


I've tried it, still the same error.
Why is it working for you folks and not for me :-/ ?
I'll have to wait for the updated version I suppose.

Regards,

Edited by syscon, 03 April 2011 - 20:17.

#Joseph

#10   joshhanson314

joshhanson314
  • Members
  • 4 posts

Posted 03 April 2011 - 20:23

I don't have it at my php install directory, I have it at the location of my oscommerce directory next to the top level index.php file. Try it there. Let me know if it works.

Best,
Josh

#11   syscon

syscon
  • Members
  • 268 posts

Posted 03 April 2011 - 20:40

This is the exact spot I put php.ini in, root server directory; there are only two files:

-rw-r--r-- 1 apache apache 554 Apr 1 18:32 index.php
drwxr-xr-x 3 apache apache 4096 Apr 1 18:32 osCommerce
-rw-r--r-- 1 apache apache 31 Apr 3 14:41 php.ini
drwxr-xr-x 6 apache apache 4096 Apr 1 18:32 public
#Joseph

#12   happyorc

happyorc
  • Members
  • 1 posts

Posted 05 May 2012 - 21:50

I created a php.ini at my installation's root with the following line and it worked fine.

date.timezone=America/New_York

Obviously use whatever time zone you want. Also, not sure if this is a quick fix to a bigger bug, but it works fine for me now. This might be the best fix for me anyway since my hosting provider's servers are in a different time zone than me anyway, and I'd like it to use my local time zone.

Best,
Josh Hanson


works great