You can easily set the time zone of your database by using an SQL command in phpMyAdmin 😊
In order to do so, you will need to open your databases via phpMyAdmin. You can check these articles for hPanel and cPanel for the full procedure.
Once in phpMyAdmin - click on SQL section:
Once in SQL section, insert the following command with the location of the time zone you would like to use, for example, SET time_zone = '+08:00';
Then simply click on the Go button and you are all done, you have successfully changed the time zone for your database
- This will only change the time zone for the current MySQL session, after current session ends time zone will be changed to a default one. For that reason it's best to use the PHP function date_default_timezone function to set your own time zone for your website.