We have installed OpenEMR 7.0 locally in our clinic. We have updated timezone in php.ini to be Asia/Karachi. Same timezone is also updated in the Admin → Globals → Locales.
Currently throughout system we see the time is 13 hours ahead. This is very strange as the time shown by system is not a valid time. I am new user so can’t attach multiple screenshots. Please see screenshots in this onedrive link: Images
Asia/Karachi is UTC+05:00 and system is adding 13 hours which becomes UTC+18:00. I don’t think UTC+18:00 is even a timezone. Also in above onedrive link are the mysql and php timezones screenshots for more clarity.
Check the timezone setting in your MySQL/MariaDB server, all the timestamps in your data tables are determined by that, setting the PHP timezone will have no effect on the records the SQL daemon is writing.
Thank you @Penguin8R - it was the issue. System timezone was set to Pacific (UTC-8). However system clock was manually updated to be in Asia/Karachi. Mysql timezone was set to SYSTEM so it was causing the problem.
I think this incorrect setup was leading to incorrect calculation in open-emr and it was showing time as UTC+13.
Thanks again!
Thank you @stephenwaite for checking. Locale setting is correct. Issue was the system timezone. It was set to Pacific (UTC-8) and system clock was manually overridden to Asia/Karachi which caused confusion.