Here we’ll cover how to set the default time zone on your Ubuntu 16.04 Apache Server.
First, open your php.ini file (found within the /etc/ directory) in a plain text editor, your file path could vary but here are a couple of example of possible file paths:
Find the following line in the php.ini file. If there’s a semi-colon at the start of this line then remove the semi-colon to uncomment this.
Set date.timezone equal to your continent and main city, a list of all available time zones can be found at http://php.net/manual/en/timezones.php
date.timezone = Europe/London
Save your php.ini file and then restart Apache using the following command in terminal:
service apache2 restart