Get 30% off your WordPress Hosting with code WPSAVE10. Launch Faster. Save More!
  • 00 Days
  • 00 Hours
  • 00 Minutes
  • 00 Seconds

How do I specify a time zone for my website (PHP)? - SIRSTEVEHQ CP

Sometimes, you may need your PHP scripts to work using a specific time zone, for example, if you're serving customers in a certain area of the world.

By default, our platform is set to be Europe/London.

To apply your own timezone, the following can be added to a .user.ini or a php.ini file:

date.timezone=TIMEZONE

In this case, TIMEZONE must be a permitted timezone, as per:

https://www.php.net/manual/en/timezones.php

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How do I change PHP maximum upload file size? - SIRSTEVEHQ CP

On SIRSTEVEHQ CP Web hosting, PHP max upload file size is set to 128M by default. This can be...

What is the PHP memory_limit? - SIRSTEVEHQ CP

The PHP memory_limit is the maximum amount of server memory that each PHP script can use.  The...

Why is my website's PHP code displaying directly on the page? - SIRSTEVEHQ CP

PHP code loading directly onto your site page rather than executing usually indicates an issue...

Why is MySQL support missing from PHP installation? - SIRSTEVEHQ CP

Our web servers run PHP 7+ as standard. In this version of PHP the MySQL module has been replaced...

Can I use parent paths in Classic ASP? - SIRSTEVEHQ CP

ASP Parent Paths are disabled on our platform. As a result, Classic ASP scripts using "../"...