1

I have apache and php running on OSX.

I have a simple page printing phpinfo().

<?php
phpinfo();

In my php.ini, no matter what I write for date.timezone, phpinfo says Europe/Zurich (both Local and Master).

I know I am modifying the correct file because if I change some other flag (short_open_tag) I see the changes immediately (after apache restart). But changing the timezone to say

[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
date.timezone = America/Los_Angeles

Nothing changes...

I've also tried

[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
date.timezone = "America/Los_Angeles"

I'm going crazy - what am I missing?

1

I am going to answer my own question.

After some research, I've realized my version of PHP was packaged by Liip. According to their website (http://php-osx.liip.ch/), they state:

Why is Europe/Zurich the default timezone? Where to change that?

Because we are based in Zurich (and Fribourg and Lausanne). Change the file in /usr/local/php5/php.d/99-liip-developer.ini to adjust that.

I did just that, solves it!

  • Where i can find this file "99-liip-developer.ini" on windows? – Shujaat May 22 '18 at 20:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.