How can I change the timezone that PHP is using?
Jump to navigation
Jump to search
You can change the timezone that PHP is using by using a custom php.ini file. More details on custom php.ini files can be found here:
How can I change PHP settings?
Here is the setting you will want to use:
<syntaxhighlight lang="bash">date.timezone = "TIMEZONE"</syntaxhighlight>
(replacing TIMEZONE with your desired timezone)
Here is an example of a properly configured setting:
<syntaxhighlight lang="bash">date.timezone = "America/Detroit"</syntaxhighlight>
You can find your timezone at the PHP website: