If this is your first visit, check our documentation. To post, register or login.
Forums / Installing on a Linux/Unix Server / date.timezone correct in phpinfo(), still shows error

date.timezone correct in phpinfo(), still shows error

Started by spmckee on 4 Apr 2012, 4:48 PM · Views: 2,201

Results 1 to 6 of 6
4 Apr 2012, 4:48 PM
#1
spmckee avatar

spmckee

New Zenner

Join Date:
Apr 2012
Posts:
6
Plugin Contributions:
0

date.timezone correct in phpinfo(), still shows error

Greetings,

I have read through many posts regarding this subject and am still running into issues. I am getting the dreaded > ERROR: date.timezone not set in php.ini. Please contact your hosting company to set the timezone in the server PHP configuration before continuing..

I have set the date.timezone via a PHP.ini file in my root directory. My hosting company requires that I also add an .htaccess file with "SetEnv TZ".

These steps seem to set the datetime and I have confirmed it with "phpinfo();" in the root directory. I has the following entry: > date.timezone America/Los_Angeles America/Los_Angeles

So why am I still seeing an error?

Thanks,
SP

6 Apr 2012, 1:11 AM
#2
jetx avatar

jetx

Zen Follower

Join Date:
Apr 2006
Posts:
425
Plugin Contributions:
0

Re: date.timezone correct in phpinfo(), still shows error

Ask your hosting company, probably Apache needs a restart.

6 Apr 2012, 1:55 AM
#3
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: date.timezone correct in phpinfo(), still shows error

spmckee:

Greetings,

I have read through many posts regarding this subject and am still running into issues. I am getting the dreaded .

I have set the date.timezone via a PHP.ini file in my root directory. My hosting company requires that I also add an .htaccess file with "SetEnv TZ".

These steps seem to set the datetime and I have confirmed it with "phpinfo();" in the root directory. I has the following entry:

So why am I still seeing an error?

Thanks,
SP

Um... what has all this got to do with zencart?

This forum is for assistance with zencart - not php configurations on a server...

I see this is your first post, so you will be forgiven... but please do not ask questions that have nothing to do with zencart (or at least are not closely related to it.)

20 years a Zencart User

6 Apr 2012, 1:59 AM
#4
spmckee avatar

spmckee

New Zenner

Join Date:
Apr 2012
Posts:
6
Plugin Contributions:
0

Re: date.timezone correct in phpinfo(), still shows error

jetx: Thanks I'll look into.

schoolboy: I'm getting this error via the ZC install, seems pretty appropriate to me.

6 Apr 2012, 2:12 AM
#5
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: date.timezone correct in phpinfo(), still shows error

spmckee:

jetx: Thanks I'll look into.

schoolboy: I'm getting this error via the ZC install, seems pretty appropriate to me.

You would probably get it trying to install MOST other sophisticated applications...

Again... pure PHP questions of this nature are entirely applicable to your host.

I would be very concerned if my host was requiring me to set custom php.ini and setEnv commands. It indicates a server that is probably very shaky.

Before you proceed consider that setting up eCommerce is complex stuff, and it requires PROPER HOSTING on a server that is configured to handle it.

Too many people have a "brother-in-law with a server, who's letting me host for free..." or "I found this really cheap host..."

If you intend trading online, taking people's money over the WWW, you owe them a duty of care, to be responsible for ensuring that their experience on your site is reilable, efficient, safe and secure...

A host that has a server that is not sufficiently configured is a host that you should really avoid.

20 years a Zencart User

6 Apr 2012, 2:33 AM
#6
drbyte avatar

drbyte

Sensei

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

Re: date.timezone correct in phpinfo(), still shows error

The Zen Cart installer is checking whether the server's master php.ini configuration has a date.timezone set. It's not checking a local override.
Get the host to configure their PHP with a date.timezone value that suits the server, and then restart the PHP/Apache/whatever services so that they take effect.

Your local override via a custom php.ini or .htaccess will be used for your live store if it's set, but is not part of the detection process currently used when assessing the server's overall configuration.

.
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.