How to change date.timezone

You can modify different php settings for your account, including timezone, using a php.ini file.

If you do not have it yet, please refer to the guidelines below on how to add it:

    How to edit php.ini file on shared servers
 

On our shared servers the"America/New_York" timezone is set by default.

To change it, you will need to update the following value in your php.ini file:

date.timezone =


 

Once configured, do not forget to save the changes.

If your account is hosted on a shared server, the suPHP configuration directive should be added to your .htaccess file to make these settings global for the entire account. You can find step-by-step instructions here.

If your account is located on a business server, no other changes are to be made.

Here you can find the guidelines on how to get the default timezone used by all date/time functions in a script.


That's it!

Was this answer helpful?

 Print this Article

Also Read

How to enable exec()

You can modify different php settings for your account using a php.ini file. We recommend using...

How to edit php.ini on shared servers

With the help of PHP Selector implemented on our shared servers, you can easily modify basic PHP...

How to - PHP Loaders

What are PHP Loaders and what is their role?As you may know, PHP files are plain text files that...

PHP modules and extensions on shared hosting servers

  PHP is an open-source scripting language that is mainly used to create dynamic web pages. Its...

How to enable register_globals

You can turn on register_globals in your php.ini file. To do this, please create a php.ini file...

Powered by WHMCompleteSolution