Forums / General Questions / PHP warning: It is not safe to rely on the system's timezone settings.

PHP warning: It is not safe to rely on the system's timezone settings.

Views: 2,768

Results 1 to 13 of 13
16 Jan 2015, 7:27 PM
#1
cseright7 avatar

cseright7

New Zenner

Join Date:
Jan 2015
Location:
United States
Posts:
3
Plugin Contributions:
0

PHP warning: It is not safe to rely on the system's timezone settings.

We are using version 1.5.1
Site is hosted on 1and1 - the version had not been updated to 1.5.4 and we were having problems with the Paypal checkout error because of the SSL3 thing (I was able to resolve that here http://www.zen-cart.com/showthread.php?214916-Important-announcement-about-POODLE-and-payment-security).
1and1 didn't want to update to 1.5.4 since they hadn't tested it enough so they had me switch to "free" mode which allowed me to make the changes listed above to the payment settings so paypal would work. That is great. The site is working fine now and check out it ok.
The problem is that when I go to login page I get this error:

Strict Standards: 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/New_York' for 'EST/-5.0/no DST' instead in /***/login.php on line 13 (folder replaced with ***** for security)

site is http://ctiastore.combat-terror.com/

I have access to FTP to fix the login.php file, but I don't know what to put there. any help would be appreciated so that I can get back into my site.

16 Jan 2015, 7:47 PM
#3
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,119
Plugin Contributions:
56

Re: PHP warning: It is not safe to rely on the system's timezone settings.

... and please, please don't let 1and1 "automatically" update your store! Those auto-updaters are all doomed for failure!

FWIW, I've got a demo site running Zen Cart v1.5.4 on 1and1 with no issues.

16 Jan 2015, 8:01 PM
#4
cseright7 avatar

cseright7

New Zenner

Join Date:
Jan 2015
Location:
United States
Posts:
3
Plugin Contributions:
0

Re: PHP warning: It is not safe to rely on the system's timezone settings.

I have no idea how to manually update the site from 1.5.1 to 1.5.4 - i read through the tutorial but honestly not sure if I want to mess with that. I am sure that would resolve the issue - but I am on a tight schedule because I am leaving soon for a 5 day conference. Any tips?

16 Jan 2015, 8:15 PM
#6
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: PHP warning: It is not safe to rely on the system's timezone settings.

cseright7:

I have no idea how to manually update the site from 1.5.1 to 1.5.4 - i read through the tutorial but honestly not sure if I want to mess with that.
lat9 is right.. you can't let 1and1 automatically update your site.. Hopefully this site is you BUSINESS and not some hobby site.. If it's the latter, then make a BUSINESS INVESTMENT and hire someone to do the upgrade.. I PROMISE that if you let 1and1's auto installers do this for you you WILL be back (here or talking to 1and1's support folks) because their upgrade blew something up..

cseright7:

I am sure that would resolve the issue - but I am on a tight schedule because I am leaving soon for a 5 day conference. Any tips?No actually it won't.. The "tip" comes from the link that was posted earlier..
IF THAT STILL DOES NOT WORK ... THEN YOU HAVE A BIGGER SERVER PROBLEM!
If you continue to get errors related to date.timezone after following these instructions, then you must contact your hosting company for help in properly setting date.timezone in your server's PHP configuration. You will have to solve it with their help.

If you tried the changes recommended and the issue PERSISTS, then you need to contact your host..

My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

16 Jan 2015, 10:44 PM
#7
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: PHP warning: It is not safe to rely on the system's timezone settings.

cseright7:

I have no idea how to manually update the site from 1.5.1 to 1.5.4 - i read through the tutorial but honestly not sure if I want to mess with that. I am sure that would resolve the issue - but I am on a tight schedule because I am leaving soon for a 5 day conference. Any tips?

DivaVocals:

lat9 is right.. you can't let 1and1 automatically update your site.. Hopefully this site is you BUSINESS and not some hobby site.. If it's the latter, then make a BUSINESS INVESTMENT and hire someone to do the upgrade.. I PROMISE that if you let 1and1's auto installers do this for you you WILL be back (here or talking to 1and1's support folks) because their upgrade blew something up..

No actually it won't.. The "tip" comes from the link that was posted earlier..

If you tried the changes recommended and the issue PERSISTS, then you need to contact your host..

There are several that will do this as Diva has indicated.... Every single post in here about staying away from an auto-installer should be headed... In the last week alone there have been at least 20 people that have publicly posted about the problems they have had using the auto-installers for ZC 1.5.4... have you looked at:
http://www.zen-cart.com/entry.php?3-How-do-I-rebuild-my-site-on-the-new-version-instead-of-upgrading

For the process in addition to what you have previously reviewed?

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

22 Sep 2015, 2:31 PM
#8
alexoverton avatar

alexoverton

New Zenner

Join Date:
Feb 2009
Posts:
3
Plugin Contributions:
0

Re: PHP warning: It is not safe to rely on the system's timezone settings.

mc12345678:

See: http://www.zen-cart.com/showthread.php?208662-date-timezone-patch for a possible solution.

Please could you share your connection details on your 1and1 hosting plan. Specifically the database localhost name , db port numbers, php version your are running. details of your.htaccess config (including the php select code at the top) and any other directory configs like php.ini files in directories you have had to put in to get it working Please.

Having a hell of a time getting it to work on 1and1!

Works fine on my debian box with now issue..put it on 1and1...and all hell breaks loose...arrgh..

Thanks in advance

22 Sep 2015, 2:40 PM
#9
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: PHP warning: It is not safe to rely on the system's timezone settings.

alexoverton:

Please could you share your connection details on your 1and1 hosting plan. Specifically the database localhost name , db port numbers, php version your are running. details of your.htaccess config (including the php select code at the top) and any other directory configs like php.ini files in directories you have had to put in to get it working Please.

Having a hell of a time getting it to work on 1and1!

Works fine on my debian box with now issue..put it on 1and1...and all hell breaks loose...arrgh..

Thanks in advance

To ensure others understand, I am not a user of 1and1 so I would think/expect that either the above was really directed at someone else, or that someone else will be willing to provide the requested information, though it would really help for more of an explanation of the issues, things tried, etc... If more than the issue being that all hell breaks loose...

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

22 Sep 2015, 2:40 PM
#10
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: PHP warning: It is not safe to rely on the system's timezone settings.

alexoverton:

Please could you share your connection details on your 1and1 hosting plan. Specifically the database localhost name , db port numbers, php version your are running. details of your.htaccess config (including the php select code at the top) and any other directory configs like php.ini files in directories you have had to put in to get it working Please.

Having a hell of a time getting it to work on 1and1!

Works fine on my debian box with now issue..put it on 1and1...and all hell breaks loose...arrgh..

Thanks in advance

To ensure others understand, I am not a user of 1and1 so I would think/expect that either the above was really directed at someone else, or that someone else will be willing to provide the requested information, though it would really help for more of an explanation of the issues, things tried, etc... If more than the issue being that all hell breaks loose...

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

23 Oct 2015, 2:41 AM
#11
dijenga avatar

dijenga

New Zenner

Join Date:
Nov 2010
Posts:
36
Plugin Contributions:
0

Re: PHP warning: It is not safe to rely on the system's timezone settings.

Does NO ONE know how to solve this problem with the code that installs when I install the zencart?

I cannot enter the admin section of the cart.

So, someone says "contact your host" ... and what do I tell them is the problem? Just telling them about the offending line of code? Did THEY write it???

Sorry, but I'm lost when no one will give a direct reason why something is a problem, or why it causes a problem ... followed by a common sense solution where I can edit the code to make the site work.

23 Oct 2015, 7:28 AM
#12
lruskauff avatar

lruskauff

Totally Zenned

Join Date:
Sep 2008
Location:
WA
Posts:
559
Plugin Contributions:
0

Re: PHP warning: It is not safe to rely on the system's timezone settings.

Hello
I'm confused, are you asking for help? You reference earlier interactions but I don't see any under you name? If you do need help can you please tell us more about the problem you are having?
Thanks
Linsa

24 Oct 2015, 4:46 AM
#13
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,515
Plugin Contributions:
176

Re: PHP warning: It is not safe to rely on the system's timezone settings.

Dijenga:

Does NO ONE know how to solve this problem with the code that installs when I install the zencart?

I cannot enter the admin section of the cart.

So, someone says "contact your host" ... and what do I tell them is the problem? Just telling them about the offending line of code? Did THEY write it???

Sorry, but I'm lost when no one will give a direct reason why something is a problem, or why it causes a problem ... followed by a common sense solution where I can edit the code to make the site work.

There are tons of people happy to help, but you need to help us help you ... what exactly are YOUR symptoms? You said you're lost, but you've also left us lost: "I cannot enter the admin" doesn't give us much to go on. You haven't indicated which version you've installed, what PHP version you're using, what messages are being displayed, whether any blank screen is happening, whether any errors are appearing in the /logs directory ... all of which is critical information for us to help you.

Let's start with the answers to those questions, and see where that leads us for the solution to your individual problem.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.